Skip to content

Commit

Permalink
Catch and print python exceptions when stopping nodes
Browse files Browse the repository at this point in the history
Otherwise the code at the bottom is never executed when nodes crash,
leading to no output of debug.log files on Travis.
  • Loading branch information
codablock committed Feb 21, 2019
1 parent a99d259 commit 1a4cac0
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion qa/rpc-tests/test_framework/test_framework.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,12 @@ def main(self):

if not self.options.noshutdown:
print("Stopping nodes")
stop_nodes(self.nodes)
try:
stop_nodes(self.nodes)
except BaseException as e:
success = False
print("Unexpected exception caught during shutdown: " + repr(e))
traceback.print_tb(sys.exc_info()[2])
else:
print("Note: dashds were not stopped and may still be running")

Expand Down

0 comments on commit 1a4cac0

Please sign in to comment.