* Fix filter and test documentation syntax errors.
Most cases were strings that were YAML-parsable as dictionaries due to colons,
sometimes of the form `str: str`, and sometimes of the form `str: list`.
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Add Unit Tests To Capture Failures From 'subnet' Generator
The netaddr library returns a generator for the 'subnet' call. This works great until you use larger networks. While it is uncommon to encounter it in IPv4 usage it is trivial to hit it in IPv6.
* Switch To Calculating Networking Information Directly For Performance
This replaces the inefficient generator for 'subnet' and uses math to determine the result directly. Since a list is not returned directly to the client in the implemented cases this works great and is fast.
A further optimization at least on the logic of this might be to break the different cases implemented by the filter out into unique functions. I did not do this yet because I wanted to get feedback on this direction.
* Changelog Fragment For PR / Bugfix
Adding changelog fragment that references source issue.
* Dropping Python 3.7 Bypass Removes Need For 'sys' Module
A test for ipsubnet was bypassed under 3.7 because of an inconsistent return value w/3.6 and 2.7. I removed the bypass and changed the behavior of the filter to raise an AnsibleFilterError in all versions of Python.
* Add A Pair of Integration Tests
These demonstrate the issue with the current implementation and would normally stall out while building the list of possible subnets from the generator.
* Address Changelog Feedback
I kept the performance item as a bugfix but bumped the typing to a minor change.
* Add 'netaddr' To Integration Test 'requirements.txt'
* The `ansible-test integration --docker` requires this line in requirements.txt to pass the 'netaddr' related tests
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Replace str -> to_text
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Kate Case <this.is@katherineca.se>
* Enable update docs
* Remove foo
* Changelog
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Fix validate-module sanity
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Bradley A. Thornton <bthornto@redhat.com>
Prepare for release utils 2.5.2
SUMMARY
ISSUE TYPE
Docs Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Nilashish Chakraborty <nilashishchakraborty8@gmail.com>
Improve ut coverage
SUMMARY
Add more testcases for ipaddr filter
ISSUE TYPE
COMPONENT NAME
ipaddr.py
ADDITIONAL INFORMATION
Reviewed-by: Nilashish Chakraborty <nilashishchakraborty8@gmail.com>
Reviewed-by: Ashwini Mhatre <mashu97@gmail.com>
Reviewed-by: Sagar Paul <sagpaul@redhat.com>
Add 'netaddr' To 'requirements.txt' For Unit Tests
This enables 'ansible-test --docker' and 'ansible-test --venv' to be able to leverage 'netaddr' and pass tests
SUMMARY
This adds the 'netaddr' python module to the requirements specific to unit tests. This allows 'ansible-test' to work for '--docker' and '--venv' without manual intervention.
I also re-ordered the current list to be alphabetical.
Fixes#142
ISSUE TYPE
Bugfix Pull Request
COMPONENT NAME
Unit tests in ansible.utils for ipsubnet
ADDITIONAL INFORMATION
git clone https://github.com/ansible-collections/ansible.utils.git
cd ansible.utils
ansible-galaxy collection build .
ansible-galaxy collection install -p . ansible-utils-\*.tar.gz
ansible-test units --docker base tests/unit/plugins/filter/test_ipsubnet.py --requirements --verbose
Reviewed-by: Ashwini Mhatre <mashu97@gmail.com>
minor doc fix
SUMMARY
in_any_network, doc fix for redundant line
ISSUE TYPE
Docs Pull Request
COMPONENT NAME
in_any_network
ADDITIONAL INFORMATION
Reviewed-by: Nilashish Chakraborty <nilashishchakraborty8@gmail.com>
prepare for release 2.5.0
SUMMARY
ISSUE TYPE
Docs Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Sagar Paul <sagpaul@redhat.com>
Reviewed-by: None <None>
Add plugin Reduce_on_network
SUMMARY
ISSUE TYPE
New Module Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Nathaniel Case <this.is@nathanielca.se>
Reviewed-by: Nilashish Chakraborty <nilashishchakraborty8@gmail.com>
Reviewed-by: None <None>
Add next nth usable filter plugin
SUMMARY
ISSUE TYPE
New Module Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Rohit Thakur <rohitthakur2590@outlook.com>
Reviewed-by: None <None>
Reviewed-by: Nathaniel Case <this.is@nathanielca.se>
Add ipsubnet filter plugin
SUMMARY
ISSUE TYPE
New Module Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Nathaniel Case <this.is@nathanielca.se>
Reviewed-by: None <None>
Add IPV6 filter plugin
SUMMARY
ISSUE TYPE
New Module Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Nathaniel Case <this.is@nathanielca.se>
Reviewed-by: None <None>
Fix issue of not running tests in network ee for some targets
SUMMARY
fix issue of some integration targets was not running in network ee.
ISSUE TYPE
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Nilashish Chakraborty <nilashishchakraborty8@gmail.com>
Reviewed-by: Matt Martz <matt@sivel.net>
Reviewed-by: Ashwini Mhatre <mashu97@gmail.com>
Reviewed-by: None <None>
Prepare for release 2.4.1
SUMMARY
This release with trivial changes is necessary for controller and ee testing.
ISSUE TYPE
Docs Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Sagar Paul <sagpaul@redhat.com>
Reviewed-by: None <None>
Bugfix: Make validate_args as generic utility function
SUMMARY
fixes: #100
ISSUE TYPE
Bugfix Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Nilashish Chakraborty <nilashishchakraborty8@gmail.com>
Reviewed-by: None <None>
Prepare for release 2.4.0
SUMMARY
ISSUE TYPE
Docs Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: GomathiselviS <None>
Reviewed-by: None <None>
Update validate to use 2.11 ArgumentSpecValidator if available
SUMMARY
fixes: #85
ISSUE TYPE
Bugfix Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Bradley A. Thornton <bthornto@redhat.com>
Reviewed-by: Ashwini Mhatre <mashu97@gmail.com>
Reviewed-by: None <None>
Prepare for release 2.3.1
SUMMARY
ISSUE TYPE
Docs Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Sagar Paul <sagpaul@redhat.com>
Reviewed-by: Nilashish Chakraborty <nilashishchakraborty8@gmail.com>
Add support for the validation of formats to the json schema validator
SUMMARY
fixes: #81
ISSUE TYPE
Bugfix Pull Request
COMPONENT NAME
ADDITIONAL INFORMATION
Reviewed-by: Ganesh Nalawade <None>