Merge pull request #60 from szarya/hotfix/fix_synchronous_flag

Move synchrounous pop uphill, so it doesn't end up as a flag in the a…
This commit is contained in:
Spikeophant 2019-08-06 16:17:21 -07:00 committed by GitHub
commit bcc1321563
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -283,6 +283,8 @@ class Terraform(object):
""" """
capture_output = kwargs.pop('capture_output', True) capture_output = kwargs.pop('capture_output', True)
raise_on_error = kwargs.pop('raise_on_error', False) raise_on_error = kwargs.pop('raise_on_error', False)
synchronous = kwargs.pop('synchronous', True)
if capture_output is True: if capture_output is True:
stderr = subprocess.PIPE stderr = subprocess.PIPE
stdout = subprocess.PIPE stdout = subprocess.PIPE
@ -302,7 +304,6 @@ class Terraform(object):
p = subprocess.Popen(cmds, stdout=stdout, stderr=stderr, p = subprocess.Popen(cmds, stdout=stdout, stderr=stderr,
cwd=working_folder, env=environ_vars) cwd=working_folder, env=environ_vars)
synchronous = kwargs.pop('synchronous', True)
if not synchronous: if not synchronous:
return p, None, None return p, None, None