mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-03 06:28:27 -04:00
Tools: size_compare_branches.py: upon process failure write out a file containing diagnostics
This commit is contained in:
parent
1748711b99
commit
34bc01ec71
@ -267,6 +267,12 @@ class SizeCompareBranches(object):
|
|||||||
print(output)
|
print(output)
|
||||||
self.progress("Process failed (%s)" %
|
self.progress("Process failed (%s)" %
|
||||||
str(returncode))
|
str(returncode))
|
||||||
|
try:
|
||||||
|
path = pathlib.Path(self.tmpdir, f"process-failure-{int(time.time())}")
|
||||||
|
path.write_text(output)
|
||||||
|
self.progress("Wrote process failure file (%s)" % path)
|
||||||
|
except Exception:
|
||||||
|
self.progress("Writing process failure file failed")
|
||||||
raise subprocess.CalledProcessError(
|
raise subprocess.CalledProcessError(
|
||||||
returncode, cmd_list)
|
returncode, cmd_list)
|
||||||
return output
|
return output
|
||||||
|
Loading…
Reference in New Issue
Block a user