Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support the include_host_filters #1347

Merged
merged 6 commits into from
Dec 6, 2023
Merged

Conversation

xu001186
Copy link
Contributor

The azure_rm inventory currently only supports the blacklist filter through exclude_host_filter; the include_host_filters is added to support the whitelist filter. By default, include_host_filters is set to [true] to avoid impacting any of the existing azure_rm inventory configurations.

Copy link
Collaborator

@Fred-sun Fred-sun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small change request!

plugins/inventory/azure_rm.py Outdated Show resolved Hide resolved
plugins/inventory/azure_rm.py Outdated Show resolved Hide resolved
@Fred-sun Fred-sun added medium_priority Medium priority work in In trying to solve, or in working with contributors inventory plugin/Inventory/azure_rm.py related issues labels Nov 28, 2023
@xu001186
Copy link
Contributor Author

Small change request!

All the changes have been applied.

Copy link
Collaborator

@Fred-sun Fred-sun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

small change request!

plugins/inventory/azure_rm.py Outdated Show resolved Hide resolved
@xu001186
Copy link
Contributor Author

small change request!

I am curious, is there a lint tool that you are using to find this format error?

@Fred-sun
Copy link
Collaborator

@xu001186 In addition to the module doing the desired result correctly, we need to do a check on sanity and lint formatting. You can do this with the following command. Thank you!

Install ansible-lint: pip3 install ansible-lint
ansible-lint check:  ansible-lint plugins/inventory/azure_rm.py
sanity check: ansible-test plugins/inventory/azure_rm.py

@Fred-sun
Copy link
Collaborator

@xu001186 Please help fix the follow sanity erorr! Thank you very much!

ERROR: Found 10 pep8 issue(s) which need to be resolved:
ERROR: plugins/inventory/azure_rm.py:226:72: W291: trailing whitespace
ERROR: plugins/inventory/azure_rm.py:344:34: E231: missing whitespace after ','
ERROR: plugins/inventory/azure_rm.py:345:55: E231: missing whitespace after ','
ERROR: plugins/inventory/azure_rm.py:345:74: E231: missing whitespace after ','
ERROR: plugins/inventory/azure_rm.py:346:1: W293: blank line contains whitespace
ERROR: plugins/inventory/azure_rm.py:347:34: E231: missing whitespace after ','
ERROR: plugins/inventory/azure_rm.py:348:48: E231: missing whitespace after ','
ERROR: plugins/inventory/azure_rm.py:348:67: E231: missing whitespace after ','
ERROR: plugins/inventory/azure_rm.py:349:1: W293: blank line contains whitespace
ERROR: plugins/inventory/azure_rm.py:351:5: E303: too many blank lines (2)

@Fred-sun
Copy link
Collaborator

@xu001186 Thanks for your udpate! I will push for merge as soon as possible!

@Fred-sun Fred-sun added ready_for_review The PR has been modified and can be reviewed and merged and removed work in In trying to solve, or in working with contributors labels Nov 29, 2023
@xuzhang3 xuzhang3 merged commit a867b33 into ansible-collections:dev Dec 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
inventory plugin/Inventory/azure_rm.py related issues medium_priority Medium priority ready_for_review The PR has been modified and can be reviewed and merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants