Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2822)

Unified Diff: download_from_google_storage.py

Issue 923473002: [download_from_google_storage] Don't list ALL objects to check for ACLs (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: Remove spurious sha1 Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | upload_to_google_storage.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: download_from_google_storage.py
diff --git a/download_from_google_storage.py b/download_from_google_storage.py
index 0f53ea46e93be9297fb60fb3f99d39b7177f64d8..5c1df0324c4c12a749b9abc2977420dcfdc4ad30 100755
--- a/download_from_google_storage.py
+++ b/download_from_google_storage.py
@@ -105,18 +105,6 @@ class Gsutil(object):
return (code, out, err)
-def check_bucket_permissions(base_url, gsutil):
- code, _, ls_err = gsutil.check_call('ls', base_url)
- if code != 0:
- print >> sys.stderr, ls_err
- if code == 403:
- print >> sys.stderr, 'Got error 403 while authenticating to %s.' % base_url
- print >> sys.stderr, 'Try running "download_from_google_storage --config".'
- elif code == 404:
- print >> sys.stderr, '%s not found.' % base_url
- return code
-
-
def check_platform(target):
"""Checks if any parent directory of target matches (win|mac|linux)."""
assert os.path.isabs(target)
@@ -454,12 +442,6 @@ def main(args):
base_url = 'gs://%s' % options.bucket
- # Check we have a valid bucket with valid permissions.
- if not options.no_auth:
- code = check_bucket_permissions(base_url, gsutil)
- if code:
- return code
-
return download_from_google_storage(
input_filename, base_url, gsutil, options.num_threads, options.directory,
options.recursive, options.force, options.output, options.ignore_errors,
« no previous file with comments | « no previous file | upload_to_google_storage.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698