-
Notifications
You must be signed in to change notification settings - Fork 113
Fix ansible 2.20.xx deprecation warnings #898
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
Conversation
|
I kicked off the tests, a couple of them are failing. |
I dug into it, and all these fails seem unrelated to the patch:
This is just a common CI job fail due to network issue
This seems to be an issue with the CI itself
These are not the lines I modified, this seems to be an unrelated issue |
Andersson007
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Perdu thanks, yes, they look unrelated, let's ignore them for now
Would you like to tackle the following errors here or maybe to fix them in another PR?:)
01:27 ERROR: plugins/module_utils/postgres.py:22:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (50%)
01:27 ERROR: plugins/modules/postgresql_copy.py:184:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (0%)
01:27 ERROR: plugins/modules/postgresql_info.py:159:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (50%)
01:27 ERROR: plugins/modules/postgresql_publication.py:257:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (0%)
01:27 ERROR: plugins/modules/postgresql_query.py:269:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (50%)
01:27 ERROR: plugins/modules/postgresql_script.py:219:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (50%)
01:27 ERROR: plugins/modules/postgresql_subscription.py:217:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (0%)
01:27 ERROR: plugins/modules/postgresql_tablespace.py:195:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (0%)
01:27 ERROR: plugins/modules/postgresql_user_obj_stat_info.py:110:0: ansible-bad-import-from: Import iteritems from the Python standard library equivalent instead of ansible.module_utils.six (0%)
|
The RHEL failures are addressed in #899 , let's not test against really ancient stuff |
SUMMARY
ansible 2.20 deprecates importing from
ansible.module_utils._text. This displays warnings to users of the modules.For instance, this tasks:
yields these warnings:
This commit fixes all related warning by using
ansible.module_utils.common.text.convertersas requested by ansible.ISSUE TYPE
COMPONENT NAME
Happens in various places