Commit Graph

588 Commits (b0fb8d570df94ed4e457adaa827d1ce9b51ade00)

Author SHA1 Message Date
Olivier Robin e88997a261 Add default XCode for iOS11.3+
These whould use XCode13

Change-Id: Idb1f0a30ed1c37e421f2d7fb05f5e6f1e017c431
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3340948
Reviewed-by: Jeff Yoon <jeffyoon@google.com>
Auto-Submit: Olivier Robin <olivierrobin@chromium.org>
Commit-Queue: Olivier Robin <olivierrobin@chromium.org>
3 years ago
Garrett Beaty 18785bb297 Fix the environment for calling git number.
Calling git number requires that that depot tools is on the path so that
git-number can be found and requires the CHROME_HEADLESS environment
variable to be set.

Change-Id: Iabb8ec6732ca2bcc0f3209449e23a7d0a4f629e3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3314033
Auto-Submit: Garrett Beaty <gbeaty@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
3 years ago
Alex Gough 98be56f2e0 [windows_sdk] allow env json to not be relative
SetEnv json entries in cipd packages for more recent Windows SDKs are
changed from:

       [
         "..",
         "..",
         "win_sdk",
         "Include",
         "10.0.17134.0",
         "um"
       ],

to

       [
         "Windows Kits",
         "10",
         "Include",
         "10.0.19041.0",
         "um"
       ],

so we should accept these paths now.

R=iannucci@chromium.org

Bug: 1250098
Change-Id: I56c84bc5ed46dda354e018b0abac2fae0bad8199
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3296663
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Commit-Queue: Alex Gough <ajgo@chromium.org>
3 years ago
Anthony Polito 8676aa925e Give better error message when proc fails to execute.
Change-Id: I9dcbaa6dd287f0a5c2a749cfdf4607bddbf04734
BUG: 1274851
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3307919
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Anthony Polito <apolito@google.com>
3 years ago
Garrett Beaty 320a1caf81 Add a method to the git API for running git number.
Change-Id: Ieac13aac86df1c3e759f5aa66015ee6a3ac5c826
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3307495
Commit-Queue: Garrett Beaty <gbeaty@google.com>
Auto-Submit: Garrett Beaty <gbeaty@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
3 years ago
Garrett Beaty 2e486c0d9d Replace can_fail_build with raise_on_failure.
The step API now supports the same functionality that can_fail_build
provides, so standardize on that argument rather than maintaining a
duplicate mechanism.

Bug: 1274644
Change-Id: Idcc3c0dacbab8d2d786b27ec277713063da6d334
Recipe-Manual-Change: build_limited
Recipe-Manual-Change: infra
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3301439
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Garrett Beaty <gbeaty@google.com>
3 years ago
Garrett Beaty 51d99b2f3a Fix the use of raw_io output placeholders.
In order to enforce that the test data provided for placeholders is of
the appropriate type (text vs binary), existing mismatches must be
resolved. This will prevent type mismatch issues from occurring when
switching builders to use python3.

Bug: 1273548
Change-Id: I83da25432b67853992d7771aba558fd38520a24e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3300310
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Garrett Beaty <gbeaty@google.com>
3 years ago
recipe-roller b23a88a7c7 Roll recipe dependencies (nontrivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (recipe_engine) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8829745138191541841

Please review the expectation changes, and LGTM+CQ.

recipe_engine:
206cd301ad
  206cd30 (gbeaty@chromium.org)
      Remove the log from write_raw.

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

R=dpranke@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ifb9fe37d3d17fdb9b13ddab317c3357bf4e014b1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3298693
Auto-Submit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Garrett Beaty <gbeaty@google.com>
Reviewed-by: Garrett Beaty <gbeaty@google.com>
3 years ago
Alex Gough 1c7dec337d [windows_sdk] Use correct path within cipd package
Previous CL[0] had the paths inside the SDK wrong so did not
correctly find the SetEnv.x64.json files in recent cipd packaged
SDKs. The 'win_sdk' portion was not necessary.

Downloading the cipd packages and verifies the old and new paths:

gci . -File -Recurse | Where-Object {$_.Name -match 'SetEnv.x64.json'}

CPID-----------------\
C:\src\dt\tmp\new-sdk\ Windows Kits\10\bin\SetEnv.x64.json
C:\src\dt\tmp\old-sdk\ win_sdk\bin\SetEnv.x64.json

[0] https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3283800

R=iannucci@chromium.org

Bug: 1250098
Change-Id: I579fd288824ca9014176b7b1c221affd966fb953
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3290913
Commit-Queue: Robbie Iannucci <iannucci@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
4 years ago
Robert Iannucci 41ed8341a5 [windows_sdk] Fix json finder arguments.
R=bryner

Bug: 1250098
Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: build_limited
Recipe-Nontrivial-Roll: infra
Change-Id: If19660a8ae9f1c3f4946b9367e150d2bf9b097a3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3288863
Reviewed-by: Brian Ryner <bryner@google.com>
Commit-Queue: Brian Ryner <bryner@google.com>
Commit-Queue: Robbie Iannucci <iannucci@chromium.org>
Auto-Submit: Robbie Iannucci <iannucci@chromium.org>
4 years ago
Robert Iannucci 2efe3d74ba [windows_sdk] Make sdk json-finding more flexible.
R=ajgo@google.com

Bug: 1250098
Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: build_limited
Recipe-Nontrivial-Roll: infra
Change-Id: I0a65193ed3c880ecfabef222ca85ea77bc3a75da
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3283800
Auto-Submit: Robbie Iannucci <iannucci@chromium.org>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Alex Gough <ajgo@google.com>
4 years ago
Scott Lee 376ce660a5 Remove tandrii@ from OWNERS under depot_tools
Missing changes from https://chromium-review.googlesource.com/q/owner:tandrii%2540google.com+%2522remove+tandrii%2540%2522
(and nodir@)

Change-Id: I9ae573f2b01bcc5e65e17202b90bc724210cd971
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3252670
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Commit-Queue: Scott Lee <ddoman@chromium.org>
4 years ago
Michael Moss 9c28af45e6 Add ability to generically call most Gerrit APIs.
This will make it easier to call new or uncommon Gerrit APIs, without
needing to add dedicated methods for each one. This also makes it easier
to debug API calls by exposing the raw response data, which is often
processed or filtered in the existing wrapper methods.

BUG=1052179
R=linxinan@chromium.org

Change-Id: I0b594a9fdaabae4b0ebb379dc5473f4d6de67a13
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3235714
Auto-Submit: Michael Moss <mmoss@chromium.org>
Reviewed-by: Dirk Pranke <dpranke@google.com>
Reviewed-by: Xinan Lin <linxinan@chromium.org>
Commit-Queue: Dirk Pranke <dpranke@google.com>
4 years ago
Gavin Mak 5cffc195c9 Don't check refspecs when running git cat-file
bot_update fetches +refs/branch-heads/* but also checks git cat-file -e
+refs/branch-heads/* which fails.

Bug: 1261879
Change-Id: Ic902eebcb7301aeae32e1a8775e3babf9fdedea9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3234885
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Xinan Lin 57f8581806 Add option to always "set bot-commit+1" in update_files() method
If one uses update_files() method to file a chain of CLs and wants
to submit them together, they have to set submit=False to wait for the
last CL. As a result, users have to run `set Bot-Commit+1` for each CL
at their side, which is annoying.

This change makes the gerrit module to handle that, and callers only
need to submit the chain.

BUG=1261724
TEST=train

Change-Id: If7d420d8d3c40b1d462284395cdc87ac680d0918
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3235388
Commit-Queue: Xinan Lin <linxinan@chromium.org>
Reviewed-by: Dirk Pranke <dpranke@google.com>
Reviewed-by: Michael Moss <mmoss@chromium.org>
4 years ago
Michael Moss b6ce244503 Add 'create tag' support to gerrit_client and gerrit recipe_module.
BUG=1052179
R=dpranke@google.com, linxinan@chromium.org

Change-Id: I6e220b70e63d990e9257d9fe4d107de7dbd2eb81
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3232849
Auto-Submit: Michael Moss <mmoss@chromium.org>
Commit-Queue: Michael Moss <mmoss@chromium.org>
Reviewed-by: Xinan Lin <linxinan@chromium.org>
Reviewed-by: Dirk Pranke <dpranke@google.com>
4 years ago
Josip Sokcevic 1efe7c7e7b Use sigkill instead of sigterm on a stale process
Only hanging process recorded so far is gsutil. Sending sigterm doesn't
result in successfully terminating the process. Instead, use sigkill.

R=gavinmak@google.com

Bug: 1255228
Change-Id: Iad354284422676df804c68cb6f18c7db723bf862
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3232250
Auto-Submit: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak 80fc559f70 Add gerrit repo to gclient config
This change removes the need for the Gerrit plugin recipe to clone the
Gerrit repo itself.

Recipe-Nontrivial-Roll: infra
Bug: 1196790
Change-Id: I3d6bb71a2e95c50c4dc29345ad24e482177233d5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3224087
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Josip Sokcevic 830c8fadf8 Remove verbose debug information from bot_update
It's generaly not useful and makes it harder to understand bot_update
logs. If we need to debug specific builders, we can set environment
variables in the recipe itself.

R=apolito@google.com

Bug: 1255228
Change-Id: I18fc6ee8cb15b30bc3a4422ddd04979189bacf64
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3221250
Commit-Queue: Anthony Polito <apolito@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Garrett Beaty 4f272fd082 Decode the output for the get_timestamp operation.
Change-Id: I31007dbbbe9c76f5e4aaf8aef0001979d05c1066
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3224017
Commit-Queue: Garrett Beaty <gbeaty@google.com>
Auto-Submit: Garrett Beaty <gbeaty@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Josip Sokcevic 756e98f5aa Mark patch failures as regular failures, not infra
Patch failures shouldn't be treated as infra_failures (as long as patch
was successfully downloaded).

Prior to https://crbug.com/1207685, bot_update patch failurs were set as
successful step to work around buildbucket plugin requirements.

One alternative approach is to add necessary information into patch
failure step, by editing its presentation.

R=gavinmak@google.com

Bug: 1207685, 1255228
Change-Id: I696356d40a80536c3efbca99091536b8b25deb40
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3219890
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
4 years ago
Josip Sokcevic 4da8a3d59d Fix bot_update hanging on exception
This change starts observers as soon as possible, and wraps the entire
block that can cause an exception in try..finally. This ensures that we
stop threads are stopped.

If we notice the same behavior, it could be worth to put a cap on number
of executions per observer, and shut the thread down once reached.

R=apolito@google.com

Bug: 1255228
Change-Id: I1f165267460da02b3bbba39022c262e6c29fe86b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3213451
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
4 years ago
Josip Sokcevic 2f6c7fd28a Cache the string-escape codec at bot_update start
It looks the following speculative fix for string-escape codec worked
for depot_tools subprocess2: https://crbug.com/912292#c2.

Using the same approach for bot_update.

R=gavinmak@google.com

Bug: 1255228
Change-Id: I3244d34abad23f9fdbf648e24fc8a565df1474cb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3210521
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
4 years ago
Ben Pastene 281edf7577 Add a 'setlabel' command to gerrit_client.py
And add a hook for it in the gerrit recipe_module.

This will allow invocations of gerrit_client to set votes like
"code-review-1" or "commit-queue+1" on CLs. This will be used by bots
to control CLs they just created with update_files().

Bug: 1250084
Change-Id: I888458983165fed5882e5c37cba4a69dbfb9b810
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3207266
Commit-Queue: Ben Pastene <bpastene@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Josip Sokcevic afb027530c Revert "Update HEAD when checking out from git cache"
This reverts commit 8031f2ad8d.

Reason for revert: didn't help

Original change's description:
> Update HEAD when checking out from git cache
>
> HEAD may be different than what git cache has. This change ensures the
> correct revision is used.
>
> R=​gavinmak@google.com
>
> Bug: 1251783
> Change-Id: I4909a4d52ef70ee806c285f24693eca5173003d9
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3174363
> Auto-Submit: Josip Sokcevic <sokcevic@google.com>
> Commit-Queue: Gavin Mak <gavinmak@google.com>
> Reviewed-by: Gavin Mak <gavinmak@google.com>

Bug: 1251783
Change-Id: I35549e47fc7cd2361321a6e8c6480ec2732215fd
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3180383
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
4 years ago
Josip Sokcevic 8031f2ad8d Update HEAD when checking out from git cache
HEAD may be different than what git cache has. This change ensures the
correct revision is used.

R=gavinmak@google.com

Bug: 1251783
Change-Id: I4909a4d52ef70ee806c285f24693eca5173003d9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3174363
Auto-Submit: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
recipe-roller ffbe96997e Roll recipe dependencies (nontrivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (recipe_engine) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8835439534712066113

Please review the expectation changes, and LGTM+CQ.

recipe_engine:
63c685b872~..f28ac0ab20025138a3f46845de09d625960c2a97
  63c685b (chanli@chromium.org)
      [buildbucket] test_api: emulate luci_context based on build info
  f28ac0a (chanli@chromium.org)
      Reland "[recipe-py] expose resultdb info in LUCI_CONTEXT"

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

R=nodir@chromium.org, tandrii@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: If2d4beb72d786f852feca9f4d43e08778bf71f3b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3174366
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Andrii Shyshkalov <tandrii@google.com>
Auto-Submit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
4 years ago
Garrett Beaty f80edc2dbc Use actual ref for commit position footer in test data when provided.
* If the input revision starts with refs/ use it as the ref of the CP.
* If the input revision is of the form origin/X, use refs/heads/X as the
  ref of the CP.

Change-Id: I048883afcfe1593e877c004729f859921910c993
Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: build_limited
Recipe-Nontrivial-Roll: chrome_release
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3165297
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Auto-Submit: Garrett Beaty <gbeaty@google.com>
4 years ago
recipe-roller bc883aef4a Roll recipe dependencies (nontrivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (recipe_engine) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8836068680053499857

Please review the expectation changes, and LGTM+CQ.

recipe_engine:
1cc998a726
  1cc998a (chanli@chromium.org)
      Revert "[recipe-py] expose resultdb info in LUCI_CONTEXT"

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

R=nodir@chromium.org, tandrii@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ib3634ea557ed2a830da4101a17ad59c1dc45ca28
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3161452
Auto-Submit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Andrii Shyshkalov <tandrii@google.com>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
4 years ago
recipe-roller 287ed7c2da Roll recipe dependencies (nontrivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (recipe_engine) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8836073712359662945

Please review the expectation changes, and LGTM+CQ.

recipe_engine:
28810c312f
  28810c3 (chanli@chromium.org)
      [recipe-py] expose resultdb info in LUCI_CONTEXT

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

R=apolito@google.com, tandrii@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: I26151593ed1556b925e3184f80828e24837e7175
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3161443
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Andrii Shyshkalov <tandrii@google.com>
Auto-Submit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
4 years ago
recipe-roller 2bbd8a7680 Roll recipe dependencies (nontrivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (recipe_engine) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8836174376798977441

Please review the expectation changes, and LGTM+CQ.

recipe_engine:
ffe17790c2
  ffe1779 (yuanjunh@google.com)
      Unify Exception message when logging recipe crashes

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

R=nodir@chromium.org, tandrii@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Id39b22619c2098cc82bf6a4abdf776e2bcbc82e6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3158792
Auto-Submit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Yuanjun Huang <yuanjunh@google.com>
Reviewed-by: Yuanjun Huang <yuanjunh@google.com>
4 years ago
Yuanjun Huang 8f09549ffc [python3] Solve soft errors in the recipes of git module
These soft errors will become hard failures and block the proto module
to be marked PY2+3 in upstream recipe engine repo.


Bug: 1227140
Change-Id: I0e5fdebe7e7cf43552b525d63c12f82c96c49902
Recipe-Nontrivial-Roll: build_limited
Recipe-Nontrivial-Roll: chrome_release
Recipe-Nontrivial-Roll: infra
Recipe-Nontrivial-Roll: build
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3152784
Commit-Queue: Yuanjun Huang <yuanjunh@google.com>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
recipe-roller 78f9196431 Roll recipe dependencies (nontrivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (recipe_engine) into this repository.

The build that created this CL was
https://ci.chromium.org/b/8836604083731327505

Please review the expectation changes, and LGTM+CQ.

recipe_engine:
776c6d56a8
  776c6d5 (yuanjunh@google.com)
      [python3] Format Exception message when running steps

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

R=gavinmak@google.com, tandrii@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: I2125a87e05f4e336131890ac2dbf2d3461606842
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3150698
Auto-Submit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
Yiwei Zhang 9589b3a476 recipe: deprecate cipd module in favor of the engine supplied one
Bug: 875523
Change-Id: I99056b760cd2bd2633773ebbb8ba062219c7d6cb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3140892
Commit-Queue: Yiwei Zhang <yiwzhang@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
Oliver Newman 4b2a96e76c Remove PYTHON_VERSION_COMPATIBILITY from cipd example
This test's expectation files include exception strings, which differ
between py2 and py3. This didn't actually break the tests in the past
because one of the cipd module's transitive dependencies,
`recipe_engine/proto`, was not py3-compatible, so the test results were
ignored.

However, I'm working on making `recipe_engine/proto` py3-compatible, and
now that it is compatible, these test failures are considered fatal. See
https://logs.chromium.org/logs/infra/buildbucket/cr-buildbucket/8837185422185352433/+/u/train_recipes_at_upstream_CL/stdout

I imagine the exception-formatting issue will eventually by fixed in the
recipe engine, but until that happens these tests can't be considered
py3-compatible.

Bug: 1227140
Change-Id: I75b2b9c0090f418cb412d497e914a30155c2b12b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3140151
Auto-Submit: Oliver Newman <olivernewman@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Oliver Newman <olivernewman@google.com>
4 years ago
Gavin Mak bd0674c0d0 Fix remaining unicode py2+3 recipe module errors
Bug: 1227140
Change-Id: Ic29fff7556884935c301b35ba3995e281f178540
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3124901
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak dde93a5a74 Add PYTHON_VERSION_COMPATIBILITY to git recipe module
Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: build_limited
Recipe-Nontrivial-Roll: chrome_release
Recipe-Nontrivial-Roll: infra
Bug: 1227140
Change-Id: Ia1fc9c67dd4e8cac08bd8892696ffc6da6c6ccd3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3123944
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Gavin Mak 535213f8cf Add PYTHON_VERSION_COMPATIBILITY to tryserver recipe module
Bug: 1227140
Change-Id: I67769aaf544ee43e58c7e0499d7b2a2a258d8fe9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3116776
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Gavin Mak 094e3dd2cd Add PYTHON_VERSION_COMPATIBILITY to cipd recipe module
Bug: 1227140
Change-Id: Ic7eb822cc04b95322ff87ad8d871c8620c6b94ec
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3123751
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Gavin Mak 7d10c80e89 Add PYTHON_VERSION_COMPATIBILITY to gsutil recipe module
Bug: 1227140
Change-Id: I81ae117146980f7dca60653f88500289d130c022
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3120084
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Gavin Mak 76b679fcf2 Add PYTHON_VERSION_COMPATIBILITY to gclient recipe module
Bug: 1227140
Change-Id: I18ad289ffac1df5482a3d6a6e4484bd69a6d6929
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3123938
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Gavin Mak d254d5c20d Add PYTHON_VERSION_COMPATIBILITY to osx_sdk recipe module
Bug: 1227140
Change-Id: Ibf73f89e1b92f8aa435e2e5c82336ed46fc6de76
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3123948
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Gavin Mak 789636c3b4 Add PYTHON_VERSION_COMPATIBILITY to depot_tools recipe module
Bug: 1227140
Change-Id: Id257157f0058bfff441cca400d1830a15d694a0f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3123934
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak 1cb508122c Add PYTHON_VERSION_COMPATIBILITY to gerrit recipe module
Bug: 1227140
Change-Id: I3cea6609eb5bb6b7f392e1078eb023ca19c6fb3e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3123939
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak 326546b771 Add PYTHON_VERSION_COMPATIBILITY to presubmit recipe module
Bug: 1227140
Change-Id: Ie11384422ef3a01fe6bc02d335a3525aeb91e7d6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3123952
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak 23508d2e0d Add PYTHON_VERSION_COMPATIBILITY to git_cl recipe module
Bug: 1227140
Change-Id: Iac28ea8ead34ddf407b4c8ac981de54d48afe725
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3123947
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak 9bccf29ed4 Add PYTHON_VERSION_COMPATIBILITY to windows_sdk recipe module
Bug: 1227140
Change-Id: I5415adaa030984a4dc034851a6f21d86e53209f0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3116499
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Gavin Mak d6d5c46cf4 Add PYTHON_VERSION_COMPATIBILITY to gitiles and bot_update
Setting PYTHON_VERSION_COMPATIBILITY = PY2+3 makes "recipe.py test" run
tests in both py2 and py3.

Bug: 1227140
Change-Id: I56a47f0491cbade172e1dc1239cbf6c2a0faa64f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3116850
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Takuto Ikuta cfac7a37d9 recipes: remove unused reference to swarrming_client
Python client is deprecated.

Bug: 984869
Change-Id: I288c5ed24abf0522edaa3b2fb0b236e109d51b1c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3117447
Auto-Submit: Takuto Ikuta <tikuta@chromium.org>
Commit-Queue: Andrii Shyshkalov <tandrii@google.com>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
4 years ago
Xinan Lin f9d9909c10 Return changeinfo from update_files method
Users may need more info from a created/submitted change,
e.g. revision hash, change status(submitted or not) etc.

BUG=1236658
TEST=train
Recipe-Nontrivial-Roll: chrome_release
Change-Id: I1db57e5c6a4e58ea320526ef5f5cbb83e1b0bb60
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3102579
Commit-Queue: Xinan Lin <linxinan@chromium.org>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
Reviewed-by: Michael Moss <mmoss@chromium.org>
4 years ago
Edward Lesmes f5ed28d814 Remove ehmaldonado from OWNERS
Change-Id: Idcb5d9b66cb019d8892ff8cfe92a0a04b01ed9e1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3022311
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Sven Zheng af70e1bf3b git new-branch adds upstream_current
git new-branch --upstream_current <branch_name>
can create a new branch tracking the current branch.
I need this in my recipe so adding this flag to the
recipe module.

Bug: 1238169
Change-Id: I1816b8d78867848e7a8f80337a6d82db8b6ef777
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3095037
Commit-Queue: Sven Zheng <svenzheng@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
4 years ago
Josip Sokcevic bdc7adc6f7 Remove bot_update assumption that HEAD is main
There is no need to override refs/heads/main to be HEAD. This may not
always be true, there is no benefits of doing so and it doesn't play
well with git_cache which will set HEAD to global default branch.

R=gavinmak@google.com

Bug: 1238084
Recipe-Manual-Change: build_limited
Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: infra
Change-Id: I21ab3463baaf7f86562ab0c65c06c3ac0962a08c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3088295
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
Rakib M. Hasan 08f3e313a4 Allow users to specify the revision of the root solution checkout
This CL allows users to pass the root solution revision to the bot
update step for presubmits. The presubmit for some child repositories
of src have dependencies on src. We need to make sure that the same
branch of a src and child repositories are checked out.

Bug:1238418
Change-Id: If2ea3962d764bddd17b3d17d20e7c644f4065fe0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3085094
Reviewed-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Dirk Pranke <dpranke@google.com>
Reviewed-by: Garrett Beaty <gbeaty@chromium.org>
Commit-Queue: Rakib Hasan <rmhasan@google.com>
4 years ago
Gavin Mak f406fda0ae Revert "Fix invalid reference: refs/remotes/origin/HEAD error"
This reverts commit 2b29d0f8e6.

Reason for revert: may be causing crbug/1238425

Original change's description:
> Fix invalid reference: refs/remotes/origin/HEAD error
>
> Change-Id: Iac298a7a14b5c0b55fd199ec120fe5c37ef88fdc
> Bug: 1178944
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2757129
> Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
> Commit-Queue: Gavin Mak <gavinmak@google.com>

Bug: 1178944, 1238425
Change-Id: I131b8a347486b70289bf78978738e1a64bd460e8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3086970
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Josip Sokcevic ce332a47a9 Use main as default branch in all recipes
Recipe-Manual-Change: build
Recipe-Nontrivial-Roll: build_limited
Recipe-Nontrivial-Roll: chrome_release
Recipe-Nontrivial-Roll: chromiumos
Recipe-Nontrivial-Roll: infra
Change-Id: I89008bc07b1c3de13d9c6dd64e723fe6dc8d01d6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3015262
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Xinan Lin a992238bf0 Add params to update_files method
params in the form 'key=value' is required by gerrit_client tool,
although may not be used by the backend.

BUG=1207955
TEST=e2e

Recipe-Nontrivial-Roll: chrome_release
Change-Id: I1181868060af921f87efe55ea9f60fa37ae8b215
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3068823
Commit-Queue: Xinan Lin <linxinan@chromium.org>
Reviewed-by: Michael Moss <mmoss@chromium.org>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
4 years ago
Xinan Lin 493faf1621 Add new API to update files by gerrit module
The new API here could support users to update files to remote
repo without loading the source code to the bot.

BUG=1207955
TEST=train

Change-Id: I2970171bf5b58db0db41bab5a433fc6721b7b2aa
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3042407
Commit-Queue: Xinan Lin <linxinan@chromium.org>
Reviewed-by: Michael Moss <mmoss@chromium.org>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
4 years ago
Fumitoshi Ukai acc131cedd add infradata_rbe config
Bug: 1233386
Change-Id: I0d83113e832f264b8be613c1fd48f9d9da3c6e3c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3055264
Auto-Submit: Fumitoshi Ukai <ukai@google.com>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
Commit-Queue: Fumitoshi Ukai <ukai@google.com>
4 years ago
Yiwei Zhang 2eba529771 recipe: import engine_types instead of types from recipe_engine
Motivation: https://crrev.com/c/3050650

Bug: 1227763
Change-Id: I2e7ce3a8a5652959bdc68f4b3cd3a783d0424c36
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3055154
Commit-Queue: Robbie Iannucci <iannucci@chromium.org>
Auto-Submit: Yiwei Zhang <yiwzhang@google.com>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
4 years ago
Stephanie Kim b992c4253f tryserver getter for CL repo host/project
Allows for quick retrieval of host and project without having to parse
gerrit_change_repo_url or hard coding.

Bug:
Change-Id: I43f6e0bfda4b54d742bfa7ea20ee781162796608
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2971110
Commit-Queue: Stephanie Kim <kimstephanie@google.com>
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Gavin Mak 11f53d6949 Reland "Add python3 support to bot_update recipe module"
This is a reland of edb6e8c51f

Original change's description:
> Add python3 support to bot_update recipe module
>
> Bug: 1227140
> Change-Id: Id4938c966da54957f84f59d0aef0c68c381ad5f6
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3016032
> Reviewed-by: Josip Sokcevic <sokcevic@google.com>
> Commit-Queue: Gavin Mak <gavinmak@google.com>

Bug: 1227140
Change-Id: I2d35d29f87236ce10ecabca41712cf1c90de8136
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3022310
Reviewed-by: Anthony Polito <apolito@google.com>
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak f6228e1583 Revert "Add python3 support to bot_update recipe module"
This reverts commit edb6e8c51f.

Reason for revert: missing some py3 changes 

Original change's description:
> Add python3 support to bot_update recipe module
>
> Bug: 1227140
> Change-Id: Id4938c966da54957f84f59d0aef0c68c381ad5f6
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3016032
> Reviewed-by: Josip Sokcevic <sokcevic@google.com>
> Commit-Queue: Gavin Mak <gavinmak@google.com>

Bug: 1227140
Change-Id: If0852908b112ff6bdd4152189c7cb198eebd2c22
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3022309
Auto-Submit: Gavin Mak <gavinmak@google.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
4 years ago
Gavin Mak 56c8a27430 Add python3 support to gclient recipe module
Recipe-Nontrivial-Roll: build
Bug: 1227140
Change-Id: Ia29c154453b40015359e5ac93a533e0dd40e5c55
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3012236
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Gavin Mak 758807c0a4 Add python3 support to git recipe module
Bug: 1227140
Change-Id: I71ad53a978ecb7040b2482b97ee23ed4c1c8f59a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3010717
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Gavin Mak edb6e8c51f Add python3 support to bot_update recipe module
Bug: 1227140
Change-Id: Id4938c966da54957f84f59d0aef0c68c381ad5f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3016032
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak 7d3c9f6d1f Add python3 support to gsutil recipe module
Bug: 1227140
Change-Id: I2a27289335c66f34adaa47be1e9fd0fd13abcc56
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3010716
Commit-Queue: Anthony Polito <apolito@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Gavin Mak a138f082de Add python3 support to gitiles recipe module
This change omits python3 support for resources/gerrit_client.py

Bug: 1227140
Change-Id: Ibc8d9f1fbd28008959991688ced5818f0188f905
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3012233
Commit-Queue: Anthony Polito <apolito@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Gavin Mak 0e27bfe34f Add python3 support to cipd recipe module
Bug: 1227140
Change-Id: Id8bb07c90165a0c36741f0c797e17a227b043545
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3012230
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak 6143a9473b Add python3 support to tryserver recipe module
Bug: 1227140
Change-Id: I54b9fb426e0471543be6c7801f5d5f76ff21c6f3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3010715
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Josip Sokcevic b3d52d34cd Revert "Use main as default branch for git recipe module"
This reverts commit 6b08432689.

Reason for revert: creates CLs that are on top of stale commits, not ToT

Original change's description:
> Use main as default branch for git recipe module
>
> R=​apolito@google.com, ehmaldonado@chromium.org
>
> Recipe-Nontrivial-Roll: build_limited_scripts_slave
> Recipe-Nontrivial-Roll: chromiumos
> Recipe-Nontrivial-Roll: infra
> Change-Id: Ia0d39ae574852fa008a55e366c2320eb1845dc86
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2941678
> Commit-Queue: Josip Sokcevic <sokcevic@google.com>
> Reviewed-by: Anthony Polito <apolito@google.com>

Change-Id: I64ed8e7fbeab8cf8a0be6be4456fee400f770883
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2998588
Auto-Submit: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
4 years ago
Josip Sokcevic 6b08432689 Use main as default branch for git recipe module
R=apolito@google.com, ehmaldonado@chromium.org

Recipe-Nontrivial-Roll: build_limited_scripts_slave
Recipe-Nontrivial-Roll: chromiumos
Recipe-Nontrivial-Roll: infra
Change-Id: Ia0d39ae574852fa008a55e366c2320eb1845dc86
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2941678
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Chong Gu 473499ba26 [cipd] Add verification-timeout as a passable flag
For Fuchsia official builders, we need a way to increase
the verification timeout so that our packages are uploaded
successfully

Bug:1215771
Change-Id: Ie59dc149e2b88864afea1aaf6700a94324593196
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2973226
Commit-Queue: Chong Gu <chonggu@google.com>
Auto-Submit: Chong Gu <chonggu@google.com>
Reviewed-by: Dirk Pranke <dpranke@google.com>
4 years ago
Edward Lesmes 6d099d543d bot_update: Don't collect metrics if not running as part of a build.
When running using led, DEPOT_TOOLS_REPORT_BUILD might not be set, and
bots will try to collect metrics.

Set DEPOT_TOOLS_COLLECT_METRICS so metrics are not collected on this
case.

Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: infra
Recipe-Nontrivial-Roll: build_limited_scripts_slave
Recipe-Nontrivial-Roll: chromiumos
Change-Id: I8b1083b31ef6daf87d24544a990bee863543aa1d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2946935
Reviewed-by: Ben Pastene <bpastene@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes b508ecd932 bot_update: Initialize synced_solutions before syncing.
If sync fails, synced_solutions is not initialized, resulting in a
use-before-init error.

Bug: 1217352
Change-Id: I2367d0f8030faa571b5c2743d5d97aa4c0329a7b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2945663
Reviewed-by: Ben Pastene <bpastene@chromium.org>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 9705687c25 bot_update: Add experiment to avoid fetching if checked out revision is recent enough.
If checked-out revision is less than 6 hours old, skip fetching latest
revision.

Bug: 1199853
Change-Id: Ifd2a61055de286fe6fd94a5d43f80a1885a6931c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2911015
Reviewed-by: Erik Staab <estaab@chromium.org>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Josip Sokcevic b7f797be55 Add support for py3 presubmit
Depot tools git cl presubmit supports py2 and py3. However, presumbit
recipe only runs py2. This patch adds support for running py3 presubmit
checks too.

Bug: 1214829
Recipe-Nontrivial-Roll: build
Change-Id: I089460eaf65d4b6f1238eea13eb087fadb21cad5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2934371
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
4 years ago
Marco Georgaklis 85557a08f4 Implemented suppport for getrelatedchanges endpoint in gerrit module
The endpoint documentation can be found here:
https://gerrit-review.googlesource.com/Documentation/rest-api-changes.html#get-related-changes

This involved adding support for the command in gerrit_client and
gerrit_util and then incorporating functionality and testing into
the gerrit recipe module.

The reasoning for this is to be able to identify chained builds for
improved accuracy of the new test identification for the FLake
Endorser project.

Bug:1204163
Change-Id: Ic60c733540a9afd7ff159408b0ea9ad7aac078e2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2928016
Commit-Queue: Marco Georgaklis <mgeorgaklis@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes 50cd6e416a Reland "bot_update: Don't use gclient sync output and rely on gclient revinfo."
This is a reland of 856ccef0e9

Use a tempfile instead of stdout for gclient revinfo output

Original change's description:
> bot_update: Don't use gclient sync output and rely on gclient revinfo.
>
> In preparation for skipping gclient sync if there are no DEPS changes.
>
> Bug: 1199853
> Change-Id: Ib9b4ab803bc574a384c661765cee5e4c1de5baae
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2912259
> Reviewed-by: Anthony Polito <apolito@google.com>
> Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>

Bug: 1199853
Change-Id: Ib50c4e943cbb51e4a2463beee9b7d1dee824ad29
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2910950
Reviewed-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Gavin Mak 6d45691f60 Add rest of the plugins to gclient config
Recipe-Manual-Change: infra
Bug: 1201483
Change-Id: Id57c2e93e028baad101416bfecbf41ce136ad5b1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2904102
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Stephen Martinis e2d7d8cd9b Revert "bot_update: Don't use gclient sync output and rely on gclient revinfo."
This reverts commit 856ccef0e9.

Reason for revert: Probably broke chrome os waterfall

Original change's description:
> bot_update: Don't use gclient sync output and rely on gclient revinfo.
>
> In preparation for skipping gclient sync if there are no DEPS changes.
>
> Bug: 1199853
> Change-Id: Ib9b4ab803bc574a384c661765cee5e4c1de5baae
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2912259
> Reviewed-by: Anthony Polito <apolito@google.com>
> Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>

Bug: 1199853
Change-Id: Ib893704dffc68b02dfa7f977e751e236003b7e0b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2910949
Auto-Submit: Stephen Martinis <martiniss@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Avi Drissman <avi@chromium.org>
Commit-Queue: Stephen Martinis <martiniss@chromium.org>
Owners-Override: Avi Drissman <avi@chromium.org>
4 years ago
Edward Lesmes 856ccef0e9 bot_update: Don't use gclient sync output and rely on gclient revinfo.
In preparation for skipping gclient sync if there are no DEPS changes.

Bug: 1199853
Change-Id: Ib9b4ab803bc574a384c661765cee5e4c1de5baae
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2912259
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 6097a92db0 bot_update: Remove more unused arguments.
Change-Id: I00b32eb109cdff7e138ef5d9497eda77c33188f3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2912295
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
Edward Lesmes da8a67b497 bot_update: Remove unused arguments/code.
Change-Id: I4a6811f4dd3c5330eed821acd2dc4855aabcf483
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2911202
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Gavin Mak 6b0a611c2c Make patch failures from bot_update fail in ensure_checkout
Patch failures in bot_update return exit code 87 and 88, which are
ignored by ensure_checkout. This causes the bot_update step in recipes
to be successful despite a patch failure. This change removes these exit
codes from the accepted return codes for this step.

Bug: 1207685
Change-Id: I7bd71732a99184c96196659c6953e4d4b610c9b9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2893686
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Edward Lesmes 8c9a5b84cb bot_update: Add support for experiments.
Bug: 1199853
Change-Id: I0616f90a0cd7e4478f40ac7eaf5dbccca788d517
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2898001
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Anthony Polito 542224ebd6 Replace processObservers with a class that doesn't constantly recreate threads
I'm not saying this is why bot_update is failing, but I never trust python threads, especially not at scale. I also think the new implementation is easier to understand and less likely to have subtle mistakes if it is extended later

Change-Id: I29be55594a400fda845ea31893789104373fd0f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2892185
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Anthony Polito <apolito@google.com>
4 years ago
Zhaoyang Li 1af6d426a3 [mac_toolchain] Roll mac_toolchain version for builders using osx_sdk
The roll takes new feature to download Xcode & iOS runtimes separately.
The interface used by builder machines is untouched, but implementation
changed for new Xcode packages.

Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: infra
Recipe-Nontrivial-Roll: build_limited_scripts_slave
Bug: 1191260
Change-Id: If0554e116bcb92c0b125693e1f555e52e22c10f4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2890331
Reviewed-by: Jeff Yoon <jeffyoon@google.com>
Commit-Queue: Zhaoyang Li <zhaoyangli@chromium.org>
4 years ago
recipe-roller b47c95a58a Roll recipe dependencies (nontrivial).
This is an automated CL created by the recipe roller. This CL rolls
recipe changes from upstream projects (recipe_engine) into this repository.

Please review the expectation changes, and LGTM+CQ.

recipe_engine:
f4c9a77634
  f4c9a77 (olivernewman@google.com)
      [buildbucket] Make default git_ref consistent

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org, tandrii@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: I6b5526f445bbb7337ce8d18e10e855f7a91c587f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2885939
Auto-Submit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Andrii Shyshkalov <tandrii@google.com>
Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
4 years ago
Anthony Polito f7157ceea8 add a big of debugging info to figure out more abour bot_update failures
Change-Id: If324a6af154c4ded3b4c8d5e07a4740722318a59
BUG:1206377
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2889824
Auto-Submit: Anthony Polito <apolito@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes 7522924749 gclient: Set DEPOT_TOOLS_REPORT_BUILD to report bot metrics.
Recipe-Nontrivial-Roll: build_limited_scripts_slave
Recipe-Nontrivial-Roll: chrome_release
Recipe-Nontrivial-Roll: infra
Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: chromiumos
Change-Id: I5c7b2188a84580a0575e9e748946e66cc7140787
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2872856
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 68c71a34e1 bot_update: Set DEPOT_TOOLS_REPORT_BUILD to report bot metrics.
Recipe-Nontrivial-Roll: infra
Recipe-Nontrivial-Roll: build
Recipe-Nontrivial-Roll: build_limited_scripts_slave
Recipe-Nontrivial-Roll: chrome_release
Change-Id: I704ac523a3212ea30061948f8a9971a373d5394f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2861214
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Ben Pastene ad9487ab74 Add Cq-Depend to the list of known git footers in tryserver recipe_mod.
Gonna add a small warning in chromium's recipe when this footer is
used. Add it here so we can refer to the footer as a constant in
tryserver recipe_mod.

Bug: None
Change-Id: Ie4f9d1d208c0dad8d0df8f07b74e761da1051a1c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2864005
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Ben Pastene <bpastene@chromium.org>
4 years ago
Gavin Mak ae1b2b19ef Add gerrit_plugins gclient config
This change is needed to enable CQ for the tricium plugin.

Bug: 1201483
Change-Id: I685d04055a5cabd94c7f02a79a0b9cbc4694db0e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2847232
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Edward Lesmes 3600164d99 recipes: Specify refs/heads/master instead of origin/master for gclient config.
Bug: 1200657
Change-Id: I9362a66d12d75d26e1236f9d8516b03561fb9383
Recipe-Nontrivial-Roll: infra
Recipe-Nontrivial-Roll: build
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2837689
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 07a683430c Reland "git-cache: Add option to fetch commits."
This is a reland of 4c67f856f0
Issues should have been fixed by crrev.com/c/2838026

Original change's description:
> git-cache: Add option to fetch commits.
>
> Add option to git cache to fetch commits.
> And use it in bot_update and gclient sync to make sure
> the needed commits are present on the checkout.
>
> Change-Id: I9e90da9e3be6e7bacf714b22bf0b735463e655b6
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2829942
> Reviewed-by: Gavin Mak <gavinmak@google.com>
> Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>

Change-Id: Ie5a29737f5a75d28bc7c5c2f6cb99ec7f87cd9e8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2841046
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 93d80d8686 Revert "git-cache: Add option to fetch commits."
This reverts commit 4c67f856f0.

Reason for revert: crbug.com/1200657

Original change's description:
> git-cache: Add option to fetch commits.
>
> Add option to git cache to fetch commits.
> And use it in bot_update and gclient sync to make sure
> the needed commits are present on the checkout.
>
> Change-Id: I9e90da9e3be6e7bacf714b22bf0b735463e655b6
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2829942
> Reviewed-by: Gavin Mak <gavinmak@google.com>
> Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>

Change-Id: I31a1defb26119bcb46894ab4084d626b65c45fed
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2837413
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
4 years ago
Edward Lesmes 4c67f856f0 git-cache: Add option to fetch commits.
Add option to git cache to fetch commits.
And use it in bot_update and gclient sync to make sure
the needed commits are present on the checkout.

Change-Id: I9e90da9e3be6e7bacf714b22bf0b735463e655b6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2829942
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Jamie Madill b88488523d Reland "Reland "Remove ANGLE recipe config.""
This is a reland of 75271a0744

Should be safe to re-land now, as the roller will catch the
build error. Then we can re-land in conjunction with the
change to rename the angle gclient config.

Original change's description:
> Reland "Remove ANGLE recipe config."
>
> This is a reland of b8686d2622
> Must land after https://crrev.com/c/2831999
>
> Original change's description:
> > Remove ANGLE recipe config.
> >
> > This config is now located in the ANGLE recipe_module.
> >
> > Bug: angleproject:5114
> > Change-Id: I2c4cc51dafeb94378056c135538d0d13bac9c8cb
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2826242
> > Auto-Submit: Jamie Madill <jmadill@chromium.org>
> > Commit-Queue: Andrii Shyshkalov <tandrii@google.com>
> > Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
>
> Bug: angleproject:5114
> Change-Id: I858d50f49466707eae7194fd82713de7b0b2e6d6
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2835386
> Reviewed-by: Dirk Pranke <dpranke@google.com>
> Commit-Queue: Jamie Madill <jmadill@chromium.org>

Bug: angleproject:5114
Change-Id: I85c3d6218b790ef62b19c62eb42ec9a8622d613f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2836327
Auto-Submit: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Dirk Pranke <dpranke@google.com>
Commit-Queue: Dirk Pranke <dpranke@google.com>
4 years ago
Garrett Beaty 980c1abce4 Revert "Reland "Remove ANGLE recipe config.""
This reverts commit 75271a0744.

Reason for revert: breaks CQ for chromium/tools/build 

Original change's description:
> Reland "Remove ANGLE recipe config."
>
> This is a reland of b8686d2622
> Must land after https://crrev.com/c/2831999
>
> Original change's description:
> > Remove ANGLE recipe config.
> >
> > This config is now located in the ANGLE recipe_module.
> >
> > Bug: angleproject:5114
> > Change-Id: I2c4cc51dafeb94378056c135538d0d13bac9c8cb
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2826242
> > Auto-Submit: Jamie Madill <jmadill@chromium.org>
> > Commit-Queue: Andrii Shyshkalov <tandrii@google.com>
> > Reviewed-by: Andrii Shyshkalov <tandrii@google.com>
>
> Bug: angleproject:5114
> Change-Id: I858d50f49466707eae7194fd82713de7b0b2e6d6
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2835386
> Reviewed-by: Dirk Pranke <dpranke@google.com>
> Commit-Queue: Jamie Madill <jmadill@chromium.org>

Bug: angleproject:5114
Change-Id: I8dc93e365f8f0615207050a306350461082efafa
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2836638
Auto-Submit: Garrett Beaty <gbeaty@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Dirk Pranke <dpranke@google.com>
Reviewed-by: Dirk Pranke <dpranke@google.com>
4 years ago