swap for subprocess.call per @nsoranzo suggestion

This commit is contained in:
E Rasche
2017-09-25 17:32:05 +02:00
parent 626a3dc299
commit 41574d0222
@@ -119,9 +119,8 @@ def _handle_script_integrity(path, config):
sleep_amt = getattr(config, "check_job_script_integrity_sleep", DEFAULT_INTEGRITY_SLEEP)
for i in range(count):
try:
proc = subprocess.Popen([path], env={"ABC_TEST_JOB_SCRIPT_INTEGRITY_XYZ": "1"})
proc.wait()
if proc.returncode == 42:
returncode = subprocess.call([path], env={"ABC_TEST_JOB_SCRIPT_INTEGRITY_XYZ": "1"})
if returncode == 42:
script_integrity_verified = True
break