diff options
author | Josip Sokcevic <sokcevic@chromium.org> | 2024-03-14 23:50:33 +0000 |
---|---|---|
committer | LUCI <gerrit-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2024-03-15 19:26:10 +0000 |
commit | a3a73726129f7aa9cc12bbdc1f01700189936284 (patch) | |
tree | a1fe5d9c56397232a4be4df876e446906310254d /platform_utils.py | |
parent | fff1d2d74c2078b62cc9c2561330e41a842dc197 (diff) | |
download | git-repo-a3a73726129f7aa9cc12bbdc1f01700189936284.tar.gz |
main: Stringify project name in error_info
If a project can't be removed from checkout due to uncommitted changes
present, error.project is type of Project and not a string (as it is in
some cases). Project is not JSON serializable, resulting in exception
within exception handler:
TypeError: Object of type Project is not JSON serializable
This change casts project to string as a defensive mechanism. It also
passes project name instead of project object.
Change-Id: Ie7b782d73dc3647975755d5a3774d16ea6cd5348
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/413877
Tested-by: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Diffstat (limited to 'platform_utils.py')
0 files changed, 0 insertions, 0 deletions