Commit Graph

16 Commits (5ee6b6e6e335f345824d9cdb4f93a2bb997acb97)

Author SHA1 Message Date
Caleb Rouleau 63e216c6ef gsutil update default version to 4.30
Bug: 797463
Change-Id: Ia8f565997dfe2180586a8777c51f1f32229dbf3b
Reviewed-on: https://chromium-review.googlesource.com/986922
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Reviewed-by: Andrii Shyshkalov <tandrii@chromium.org>
Commit-Queue: Caleb Rouleau <crouleau@chromium.org>
7 years ago
Ryan Tseng 2e8d8348b8 gsutil.py: bump default version to 4.28 from 4.13
Picks up about 2 years worth of changes.  Should be relatively risk-free since
we pin gsutil.py in almost all of our scripts.

Bug:
Change-Id: Iff1365ee6d6f31e03da8d8876b6ccd0b47a033c2
Reviewed-on: https://chromium-review.googlesource.com/801355
Reviewed-by: Erik Staab <estaab@chromium.org>
Reviewed-by: Andrii Shyshkalov <tandrii@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Commit-Queue: Jao-ke Chin-Lee <jchinlee@chromium.org>
7 years ago
Chris Nardi ab816ce8ff Fix depot_tools errors that cause runhooks to be inoperable for Cygwin
The vpython/CIPD work created some errors when attempting to build on
Cygwin. This patch fixes these errors by converting Cygwin paths to
Windows paths or using the depot_tools python instead of Cygwin python.

Bug:
Change-Id: Id62f59a357fa2937c7eb843bf306ef4303b0910e
Reviewed-on: https://chromium-review.googlesource.com/745727
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Reviewed-by: Vadim Shtayura <vadimsh@chromium.org>
Commit-Queue: Robbie Iannucci <iannucci@chromium.org>
7 years ago
Ryan Tseng 83fd81f8a4 download_from_google_storage: Fix tests and rename
the tests haven't been ran by presumbit for a while because of the plural in
the filename.

At some point some post "gsutil cp" file checking happened, which
broke the tests.  This adds a callback to the fake gsutil cp so
that the expect file is copied over.

This also removes "gsutil version" checking from gsutil.py
and just assume that if the file exists, then it's good, which
should shave about 1-2s off of each gsutil.py call.

Bug: 772740,776311
Change-Id: I4fef62cfd46a849afed1f095dd6a96069376d13d
Reviewed-on: https://chromium-review.googlesource.com/707758
Commit-Queue: Ryan Tseng <hinoka@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Reviewed-by: Aaron Gable <agable@chromium.org>
7 years ago
Dan Jacques 509776ebbb [gsutil] run through "vpython" (2)
Run "gsutil" through "vpython". This ensures that the package set
accompanying it is completely controlled. This is notably important on
GCE instances, which "gsutil" expects to supply a
"google_compute_engine" package.

BUG=chromium:741001
TEST=local
  - Ran `gsutil cp` on 64-bit Linux machine, seems to work.
  - Ran `gsutil cp` on GCE instance, seems to work.

This is a reland of 23836a643f.

Change-Id: If87261abd505ef77f95b3c70b6bd23f3e798b41d
Reviewed-on: https://chromium-review.googlesource.com/656565
Reviewed-by: Nodir Turakulov <nodir@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Commit-Queue: Daniel Jacques <dnj@chromium.org>
8 years ago
Mike Bjorge aaea62b9c3 Revert "[gsutil] run through "vpython""
This reverts commit 23836a643f.

Reason for revert: This is breaking all the chromecast builders.

Original change's description:
> [gsutil] run through "vpython"
> 
> Run "gsutil" through "vpython". This ensures that the package set
> accompanying it is completely controlled. This is notably important on
> GCE instances, which "gsutil" expects to supply a
> "google_compute_engine" package.
> 
> BUG=None
> TEST=local
>   - Ran `gsutil cp` on 64-bit Linux machine, seems to work.
>   - Ran `gsutil cp` on GCE instance, seems to work.
> 
> Change-Id: Id771bc4da4de22c941b0ace4031cb0f3364feeeb
> Reviewed-on: https://chromium-review.googlesource.com/527277
> Reviewed-by: Nodir Turakulov <nodir@chromium.org>
> Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
> Commit-Queue: Daniel Jacques <dnj@chromium.org>

TBR=iannucci@chromium.org,dnj@chromium.org,nodir@chromium.org

Change-Id: Ifc3d6389720abd0fb9e3fc83c0cdd5a63b5ff94d
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: None
Reviewed-on: https://chromium-review.googlesource.com/656358
Reviewed-by: Nodir Turakulov <nodir@chromium.org>
Commit-Queue: Nodir Turakulov <nodir@chromium.org>
8 years ago
Dan Jacques 23836a643f [gsutil] run through "vpython"
Run "gsutil" through "vpython". This ensures that the package set
accompanying it is completely controlled. This is notably important on
GCE instances, which "gsutil" expects to supply a
"google_compute_engine" package.

BUG=None
TEST=local
  - Ran `gsutil cp` on 64-bit Linux machine, seems to work.
  - Ran `gsutil cp` on GCE instance, seems to work.

Change-Id: Id771bc4da4de22c941b0ace4031cb0f3364feeeb
Reviewed-on: https://chromium-review.googlesource.com/527277
Reviewed-by: Nodir Turakulov <nodir@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Commit-Queue: Daniel Jacques <dnj@chromium.org>
8 years ago
hinoka@chromium.org fdb9ce32d7 Add in option to always disable gsutil version check
In theory this shouldn't fire if gsutil is running without a tty (ie, in a subprocess).
In practice we're still seeing processes hang because it still thinks it's in a tty
This should in theory disable the prompt for good

BUG=577325,576979

Review URL: https://codereview.chromium.org/1587793002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@299714 0039d316-1c4b-4281-b951-d872f2087c98
9 years ago
dnj@chromium.org 605d81dfb3 gsutil: Parallel-safe, specify target, add clean.
- Update "gsutil.py" to be cooperatively safe when invoked
  multiple times simultaneously.
- Allow the cache directory to be overridden by the
  DEPOT_TOOLS_GSUTIL_BIN_DIR environment variable.
- Add a "--clean" flag to force "gsutil.py" to do a clean download.

BUG=chromium:452497
TEST=local
  - for i in `seq 1 50`; do ./gsutil.py --clean -- version&; done

Review URL: https://codereview.chromium.org/1346213003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296772 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
hinoka@chromium.org 493270eb15 Change default gsutil.py version to 4.13
BUG=
TESTS=
alpaca(gsutil_version) ~/depot_tools$ ./gsutil.py version                                                                                                                                                   
gsutil version: 4.13

Review URL: https://codereview.chromium.org/1237013003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@296023 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
hinoka@chromium.org 5e879a426d Hook sys.stdio directly to the gsutil subprocess for the gsutil call
So that gsutil.py config works.

I would've preferred the execv solution, but apparently that didn't work on Windows :(

BUG=451551

Review URL: https://codereview.chromium.org/870093003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293790 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
djacques@chromium.org d9c6d995fd Fix gsutil execution on Windows.
5498b95831 runs gsutil using 'os.execv',
which, on Windows, apparently causes it to return before completion.

Also add verbosity to '7z' failures on toolchain downloading.

BUG=chromium:445425
TEST=bot
  - Ran on bot, this fix solves the problem that we were seeing.

R=pgervais@chromium.org, sergeyberezin@chromium.org

Review URL: https://codereview.chromium.org/828463003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293507 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
pgervais@chromium.org 5498b95831 Made gsutil.py truly transparent
The previous version was modifying gsutil output by adding a
stacktrace upon non-zero return code, which broke existing code.

BUG=400871
R=hinoka@chromium.org

Review URL: https://codereview.chromium.org/822093002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293501 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
primiano@chromium.org df351768f2 gsutil: Use urllib2 instead of urllib.
This is similar to r247914 and r149742: urllib does not work with SSL
connections behind proxies, we need to use urllib2 instead. Doing this
should allow people behind proxies to download gsutils 4.7 after
r293413.

(Setting NOTRY here to be able to land the issue, otherwise the CQ fails when running some presubmit checks, see crbug.com/443232)

R=maruel@chromium.org, hinoka@chromium.org, pgervais@chromium.org, primiano@chromium.org
NOTRY=true

Review URL: https://codereview.chromium.org/809053002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293439 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
hinoka@chromium.org c13b0540e6 Args fix for gsutil.py
"--" is the hard keyword to separate gsutil commands from gsutil.py commands.

BUG=
R=dnj@chromium.org

Review URL: https://codereview.chromium.org/812223002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293433 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago
hinoka@chromium.org 7a79054e2f GSUtil.py wrapper script
This is for transitioning us out of the horribly outdated gsutil 3.4 thats
currently residing in depot_tools.  This script:
1. Downloads GSUtil, pinned to a version (4.6 by default).
2. Executes GSUtil with the given parameters
3. (TODO) Runs the fallback GSUtil if #2 fails.


The transition plan is:
1. Set the fallback as default, making this script a no-op
2. Modify recipes (main consumer of gsutil) to pass in --force_version 4.6
3. Switch 4.6 as the default for gsutil.py
4. Make fallback failure a loud red failure
5. Remove depot_tools/third_party/gsutil

BUG=434422

Review URL: https://codereview.chromium.org/742173002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@293320 0039d316-1c4b-4281-b951-d872f2087c98
10 years ago