diff --git a/third_party/py/googlestorage/publish_release.py b/third_party/py/googlestorage/publish_release.py index d7532029edc08..9628499c3d8e4 100644 --- a/third_party/py/googlestorage/publish_release.py +++ b/third_party/py/googlestorage/publish_release.py @@ -109,7 +109,7 @@ def _upload(auth_http, project_id, bucket_name, file_path, object_name, acl): object_name: The name within the bucket to upload to. acl: The ACL to assign to the uploaded file. """ - with open(file_path, 'r') as f: + with open(file_path, 'rb') as f: data = f.read() content_type, content_encoding = mimetypes.guess_type(file_path)