diff --git a/changelogs/fragments/86128-fix-script-decrypt-docs-mismatch.yml b/changelogs/fragments/86128-fix-script-decrypt-docs-mismatch.yml new file mode 100644 index 00000000000..0dbbb5bc6c8 --- /dev/null +++ b/changelogs/fragments/86128-fix-script-decrypt-docs-mismatch.yml @@ -0,0 +1,3 @@ +--- +minor_changes: + - script - remove the currently unsupported ``decrypt`` argument from the module documentation (https://github.com/ansible/ansible/issues/86067). \ No newline at end of file diff --git a/lib/ansible/modules/script.py b/lib/ansible/modules/script.py index 5d4b45f7822..957a542a99a 100644 --- a/lib/ansible/modules/script.py +++ b/lib/ansible/modules/script.py @@ -54,6 +54,7 @@ notes: - This module is also supported for Windows targets. - If the script returns non-UTF-8 data, it must be encoded to avoid issues. One option is to pipe the output through C(base64). + - This module will automatically unvault the script. seealso: - module: ansible.builtin.shell - module: ansible.windows.win_shell @@ -64,7 +65,6 @@ extends_documentation_fragment: - action_common_attributes - action_common_attributes.files - action_common_attributes.raw - - decrypt attributes: check_mode: support: partial diff --git a/lib/ansible/plugins/action/script.py b/lib/ansible/plugins/action/script.py index 2149bef91ca..0f096fdaadf 100644 --- a/lib/ansible/plugins/action/script.py +++ b/lib/ansible/plugins/action/script.py @@ -98,7 +98,7 @@ class ActionModule(ActionBase): if executable: executable = to_native(new_module_args['executable'], errors='surrogate_or_strict') try: - source = self._loader.get_real_file(self._find_needle('files', source), decrypt=self._task.args.get('decrypt', True)) + source = self._loader.get_real_file(self._find_needle('files', source)) except AnsibleError as e: raise AnsibleActionFail(to_native(e))