From a57a32adcc63422486cac07c0061ae07192748c3 Mon Sep 17 00:00:00 2001 From: Toshio Kuratomi Date: Wed, 6 Apr 2016 14:07:48 -0700 Subject: [PATCH] Revert "Make the 'path' param type also use abspath on the value" This reverts commit 1ffadbcc80ccda1fefef18333e8e9aac44cfd6fa. Some modules seem to have path listed for things that are "commands" -- something that may be a path to a command or a bare command that should be looked up in PATH. With this change, if they were formerly looked up inPATH they are now being made into an absolute path in the cwd. Reverting this until we can think more about whether to do this and change those modules to not use path for those parameters. --- lib/ansible/module_utils/basic.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/module_utils/basic.py b/lib/ansible/module_utils/basic.py index 55902ffa366..1af0bdb01a9 100644 --- a/lib/ansible/module_utils/basic.py +++ b/lib/ansible/module_utils/basic.py @@ -1376,7 +1376,7 @@ class AnsibleModule(object): def _check_type_path(self, value): value = self._check_type_str(value) - return os.path.abspath(os.path.expanduser(os.path.expandvars(value))) + return os.path.expanduser(os.path.expandvars(value)) def _check_type_raw(self, value): return value