Commit 16a04110 authored by Michael Achenbach's avatar Michael Achenbach Committed by Commit Bot

[test] Print more details when terminating hanging tests

This prints the same details about a process when attempting to kill it
as when termination fails with an exception. This will make it
easier to correlate the two and to see which might be hanging.

Bug: v8:8292
Change-Id: I4b6a50386d4e9d84ded55cf262f19529138654a9
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2006092Reviewed-by: 's avatarTamer Tas <tmrts@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#65837}
parent 1adb076c
......@@ -134,16 +134,16 @@ class BaseCommand(object):
def _abort(self, process, abort_called):
abort_called[0] = True
started_as = self.to_string(relative=True)
process_text = 'process %d started as:\n %s\n' % (process.pid, started_as)
try:
print('Attempting to kill process %s' % process.pid)
print('Attempting to kill ' + process_text)
sys.stdout.flush()
self._kill_process(process)
except OSError as e:
print(e)
started_as = self.to_string(relative=True)
print("Unruly process started as:\n %s\n" % started_as)
print('Unruly ' + process_text)
sys.stdout.flush()
pass
def __str__(self):
return self.to_string()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment