From f2449cd841d0c7a58a33db53455ee017f029497e Mon Sep 17 00:00:00 2001 From: Philipp Thiel Date: Fri, 20 Oct 2023 17:27:25 +0000 Subject: [PATCH] Fix accessing of non-existent exception attribute in error handler Fixed: 1488385 Change-Id: Ie401b1580091aa1ad31091e71e55b59e26e6fdc6 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/4931232 Reviewed-by: Aravind Vasudevan Reviewed-by: Josip Sokcevic Commit-Queue: Aravind Vasudevan --- gclient_scm.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gclient_scm.py b/gclient_scm.py index fd097a431..a9f665ec3 100644 --- a/gclient_scm.py +++ b/gclient_scm.py @@ -945,7 +945,7 @@ class GitWrapper(SCMWrapper): # case 4b force_switch = True else: - switch_error = '%s\n%s' % (e.message, switch_error) + switch_error = '%s\n%s' % (str(e), switch_error) if force_switch: self.Print("Switching upstream branch from %s to %s" % (upstream_branch, new_base)) @@ -1104,7 +1104,7 @@ class GitWrapper(SCMWrapper): # origin. See also http://crbug.com/520067. logging.warning( "Couldn't find usable revision, will retrying to update instead: %s", - e.message) + str(e)) return self.update(options, [], file_list) if file_list is not None: