diff options
author | Matthew Blecker <matthewb@chromium.org> | 2020-09-23 20:59:18 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-09-24 21:14:44 +0000 |
commit | 188423c4d7fec01518091cdf8efa948bc6bc714b (patch) | |
tree | a96d68943b1f16f2f3e4dc8f80cd432fcb305501 /util/ec3po | |
parent | bd444bbe8fcd5125d6793ed5969f266c53b1892f (diff) | |
download | chrome-ec-188423c4d7fec01518091cdf8efa948bc6bc714b.tar.gz |
ec3po: Stop suppressing exceptions in console and interpreter loops.
This removes catch-all "except:" blocks from ec3po console and interpreter
loops. They catch nothing in my own servod usage and testing. If they
are catching exceptions in some environments or workflows, let's find and
fix the problems.
BRANCH=none
BUG=chromium:894870
TEST=servod starts
servod stops cleanly via ctrl+c
servod stops cleanly via SIGTERM
EC, CR50, and Servo console PTYs function correctly for reading and writing
Tested with:
Atlas DUT + CR50 CCD + Servo v4
Krane DUT + CR50 CCD + Servo v4
Cave DUT + Servo Micro + Servo v4
Change-Id: I6422df9fc528aa446638a58ddfff05701c9688da
Signed-off-by: Matthew Blecker <matthewb@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2427638
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Diffstat (limited to 'util/ec3po')
-rwxr-xr-x | util/ec3po/console.py | 5 | ||||
-rw-r--r-- | util/ec3po/interpreter.py | 4 |
2 files changed, 1 insertions, 8 deletions
diff --git a/util/ec3po/console.py b/util/ec3po/console.py index 2360c02b6d..93286a9b60 100755 --- a/util/ec3po/console.py +++ b/util/ec3po/console.py @@ -905,6 +905,7 @@ def IsPrintable(byte): """ return byte >= ord(' ') and byte <= ord('~') + def StartLoop(console, command_active, shutdown_pipe=None): """Starts the infinite loop of console processing. @@ -1068,10 +1069,6 @@ def StartLoop(console, command_active, shutdown_pipe=None): except KeyboardInterrupt: pass - # TODO(crbug.com/894870): Stop suppressing all exceptions. - except: - traceback.print_exc() - finally: ep.unregister(console.master_pty) console.dbg_pipe.close() diff --git a/util/ec3po/interpreter.py b/util/ec3po/interpreter.py index 23eb6a6071..7362b8f775 100644 --- a/util/ec3po/interpreter.py +++ b/util/ec3po/interpreter.py @@ -448,10 +448,6 @@ def StartLoop(interp, shutdown_pipe=None): except KeyboardInterrupt: pass - # TODO(crbug.com/894870): Stop suppressing all exceptions. - except: - traceback.print_exc() - finally: interp.cmd_pipe.close() interp.dbg_pipe.close() |