Bug #1457
test_core_go hangs
Status:
Closed
Priority:
Normal
Assignee:
Category:
common_py
Target version:
Start date:
17 April 2014
Due date:
% Done:
100%
Estimated time:
Workflow:
New Issue
Description
For some reason, test_core_go was hanging on Celeste's machine. We nailed the problem down to some issue with the subprocess handling used to extract bzr information into the job header. No idea why this is happening, but the following diff seemed to fix things.
=== modified file 'src/common_py/Go.py'
--- src/common_py/Go.py 2012-11-22 10:36:21 +0000
+++ src/common_py/Go.py 2014-04-17 13:07:58 +0000
@@ -201,10 +201,7 @@
pass
try:
mrd = os.environ["MAUS_ROOT_DIR"]
- proc = subprocess.Popen(['bzr', 'status', mrd],
- stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
- proc.wait()
- bzr_status = proc.stdout.read()
+ bzr_status = subprocess.check_output(['bzr', 'status', mrd], stderr=subprocess.STDOUT)
except (OSError, IOError):
pass
maus_version = json_datacards["maus_version"]
Updated by Rogers, Chris over 9 years ago
- Status changed from Open to Closed
- % Done changed from 0 to 100
Committed in r718; note that there was a bug in the diff that we fail to catch errors properly when bzr doesn't exist, and this was repaired in r728