summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Sanders <nsanders@chromium.org>2018-09-07 11:00:04 -0700
committerChromeOS Commit Bot <chromeos-commit-bot@chromium.org>2018-09-18 15:38:10 +0000
commit385e01998cdca0d45fccce5f1656d091a36dd95f (patch)
tree954c4ca22a874c028214ae1dd3affe194efa06f9
parenta5ae5604bd963d6bcbe36f2b8c4cc355da44e1f3 (diff)
downloadchrome-ec-385e01998cdca0d45fccce5f1656d091a36dd95f.tar.gz
servo_updater: more informative error on fail
'Can't detect updater version' is replaced with an error specifying the failed regex string. BRANCH=None BUG=None TEST=None Change-Id: Ia3a52ee27e31d0b4aab0d8f04d5cf5f346498c37 Signed-off-by: Nick Sanders <nsanders@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1213556 Reviewed-by: Mary Ruthven <mruthven@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1230983 Reviewed-by: Martin Roth <martinroth@chromium.org> Commit-Queue: Martin Roth <martinroth@chromium.org> Tested-by: Martin Roth <martinroth@chromium.org>
-rwxr-xr-xextra/usb_updater/servo_updater.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/extra/usb_updater/servo_updater.py b/extra/usb_updater/servo_updater.py
index 1c8981efa5..82d2abd88d 100755
--- a/extra/usb_updater/servo_updater.py
+++ b/extra/usb_updater/servo_updater.py
@@ -137,7 +137,8 @@ def do_updater_version(vidpid, iface, serialno):
return 2
else:
return 6
- return 0
+ raise ServoUpdaterException(
+ "Can't determine updater target from vers: [%s]" % vers)
def findfiles(cname, fname):
"""Select config and firmware binary files.