diff --git a/lib/ansible/module_utils/basic.py b/lib/ansible/module_utils/basic.py index 519f1c2020..821f1f5d4f 100644 --- a/lib/ansible/module_utils/basic.py +++ b/lib/ansible/module_utils/basic.py @@ -2514,7 +2514,7 @@ class AnsibleModule(object): clean_args = [] is_passwd = False - for arg in to_clean_args: + for arg in (to_native(a) for a in to_clean_args): if is_passwd: is_passwd = False clean_args.append('********')