mirror of
https://github.com/freeipa/ansible-freeipa.git
synced 2026-07-30 11:24:50 +00:00
ansible_freeipa_module.py: Calm down ansible-test on print and sys.exit
The function exit_raw_json is a replacement for AnsibleModule.exit_json
without flterting out values for no_log parameters.
Ansible added checks for pylint to forbid print and also sys.exit and
fails with ansible-bad-function. As the check is not known outside of
ansible-test, the disable line needed also W0012:
# pylint: disable=W0012,ansible-bad-function
This commit is contained in:
@@ -747,8 +747,8 @@ def exit_raw_json(module, **kwargs):
|
|||||||
contains sensible data, it will be appear in the logs.
|
contains sensible data, it will be appear in the logs.
|
||||||
"""
|
"""
|
||||||
module.do_cleanup_files()
|
module.do_cleanup_files()
|
||||||
print(jsonify(kwargs))
|
print(jsonify(kwargs)) # pylint: disable=W0012,ansible-bad-function
|
||||||
sys.exit(0)
|
sys.exit(0) # pylint: disable=W0012,ansible-bad-function
|
||||||
|
|
||||||
|
|
||||||
def __get_domain_validator():
|
def __get_domain_validator():
|
||||||
|
|||||||
Reference in New Issue
Block a user