Fix ansible-test env var mixing running commands.
This commit is contained in:
parent
78eca0eb5d
commit
6be4741f72
2 changed files with 4 additions and 0 deletions
2
changelogs/fragments/ansible-test-env-alteration.yml
Normal file
2
changelogs/fragments/ansible-test-env-alteration.yml
Normal file
|
@ -0,0 +1,2 @@
|
|||
bugfixes:
|
||||
- ansible-test now properly uses a fresh copy of environment variables for each command invocation to avoid mixing vars between commands
|
|
@ -335,6 +335,8 @@ def intercept_command(args, cmd, target_name, env, capture=False, data=None, cwd
|
|||
"""
|
||||
if not env:
|
||||
env = common_environment()
|
||||
else:
|
||||
env = env.copy()
|
||||
|
||||
cmd = list(cmd)
|
||||
version = python_version or args.python_version
|
||||
|
|
Loading…
Reference in a new issue