download_from_google_storage: Do not call decode() on a string twice
This throws an exception when running with Python 3: Exception in thread Thread-1: Traceback (most recent call last): File "/usr/lib/python3.7/threading.py", line 926, in _bootstrap_inner self.run() File "/usr/lib/python3.7/threading.py", line 870, in run self._target(*self._args, **self._kwargs) File "/home/rakuco/src/depot_tools/download_from_google_storage.py", line 259, in _downloader_worker_thread file_url = '%s/%s' % (base_url, input_sha1_sum.decode()) AttributeError: 'str' object has no attribute 'decode' We are already calling bytes.decode() in enumerate_input(), whose output is passed to _downloader_worker_thread(). Bug: 984182, 1007872 Change-Id: I55c4835192caf69a8dee9e89ae1bb5531f4bacae Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/1844832 Auto-Submit: Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com> Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org> Reviewed-by:Edward Lesmes <ehmaldonado@chromium.org>
Showing
Please
register
or
sign in
to comment