commit | f7b8f8f3cd77ecbd16c932525f1328110b9a4ca5 | [log] [tgz] |
---|---|---|
author | Vadim Shtayura <vadimsh@chromium.org> | Mon Nov 15 19:10:05 2021 +0000 |
committer | LUCI CQ <infra-scoped@luci-project-accounts.iam.gserviceaccount.com> | Mon Nov 15 19:10:05 2021 +0000 |
tree | a9fa0b0b9f018a17c4a0dce4fbed06ba190d78dc | |
parent | b9e694ce136344e1552a6cd4879b46df271aa982 [diff] [blame] |
Fix bytes vs str error in DownloadGerritHook. It fails with: `write() argument must be str, not bytes`. R=sokcevic@google.com Change-Id: If6787140ea863ce3761a5c3747eb0b857b22fa47 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3276505 Reviewed-by: Josip Sokcevic <sokcevic@google.com> Commit-Queue: Vadim Shtayura <vadimsh@chromium.org>
diff --git a/git_cl.py b/git_cl.py index fedd53e..3540382 100755 --- a/git_cl.py +++ b/git_cl.py
@@ -3012,7 +3012,7 @@ This is necessary because urllib is broken for SSL connections via a proxy. """ - with open(destination, 'w') as f: + with open(destination, 'wb') as f: f.write(urllib.request.urlopen(source).read())