Commit Graph

11351 Commits (f41ea508908df01a047a2d93351a2b2caeeafd39)
 

Author SHA1 Message Date
Devon Loehr 5a3c9438e6 `git cl split`: Name sub-branches by hash
`git cl split` operates by creating a new git branch for each CL
it uploads. It names this branch based on the directory of the files
in the CL. It uses this convention when resuming an interrupted upload:
it skips branches that already exist.

However, this approach is brittle for several reasons:
- The splitting is nondeterministic, so there's no guarantee that CLs
with the same directories will be generated when re-run. Even if they
are, there's no guarantee they'll have exactly the same files.
- For CLs with multiple directories, it uses an arbitrary one, so it
may not choose the same name a second time
- It bakes in an assumption that every CL is defined by the directories
it draws files from.

This CL alleviates this issues by instead naming branches using the hash
of their contained files. This ensures that, with extremely high
probability, branches will have the same name if and only if they have
the same (sorted) list of files. Thus resumed uploads can safely skip
existing branches.

Bug: 389069356
Change-Id: I19bf7cd6ff8b0127f5906384f7f43b3e40ac8fee
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6236622
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Devon Loehr <dloehr@google.com>
3 months ago
Anne Redulla 6c81fd0ae3 Revert "[win-bootstrap] Cleanup update_depot_tools.bat for lack of git-for-windows"
This reverts commit 524abbc50e.

Reason for revert: restore calling `bootstrap\win_tools.bat` on git error to fix b/394767578

Original change's description:
> [win-bootstrap] Cleanup update_depot_tools.bat for lack of git-for-windows
>
> Bug: b/360206460
> Change-Id: I1a4d9ac8a4e0f19356e22bc15a664cc838e52cd3
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6205947
> Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
> Commit-Queue: Anne Redulla <aredulla@google.com>

Bug: b/360206460
Change-Id: Ifdec35e6ce594688f461f132f302c5b803640409
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6238906
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Anne Redulla <aredulla@google.com>
3 months ago
Gavin Mak 912a744103 Add next steps to 'git cl presubmit' cog error message
This updates the presubmit error message when running on Cog to
include instructions on how to trigger presubmits. This also
standardizes the messaging across git cl presubmit/web/presubmit.

Bug: 394615879
Change-Id: Iaa8857268cd43219f7502eb34388034890a919dc
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6240212
Reviewed-by: Andy Perelson <ajp@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
3 months ago
Dirk Pranke 7cffe56af4 Add UnixLocalPath*() in presubmit_support.
This adds AffectedFile.UnixLocalPath(), Change.UnixLocalPaths(), and
input_api.UnixLocalPaths() to the presubmit support APIs, so that we can
check paths in a platform-independent manner (i.e., not have to worry
about whether we're running on Windows and might need to handle
backslashes).

Change-Id: I1a424825384cb950ef2d4d3008c9c6e60028cf07
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6236404
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Dirk Pranke <dpranke@google.com>
3 months ago
recipe-roller 4389013470 Roll recipe dependencies (trivial).
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/8723724667323230897

recipe_engine:
2a60cc45d1
  2a60cc4 (chromium-autoroll@skia-public.iam.gserviceaccount.com)
      Roll CAS Client from 3521f7751453 to 292f95eae340

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I54087428b6d150c918f55856319f08c057a0b761
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6237980
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
KS Yim 781de9e7c4 Update git path for ytdevinfra_github config
R=yim@chromium.org

Bug:375245875
Change-Id: I146b026e4cd1129760d9153efa43c2fd8a37ddf6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6237197
Commit-Queue: Yiwei Zhang <yiwzhang@google.com>
Auto-Submit: K. S. Yim <yim@google.com>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
3 months ago
Devon Loehr f99834cd29 cl split: Refactor splitting datastructure
This is a preparatory CL which refactors some internal logic to make
writing future CLs easier. In particular, it changes from treating a
CL as "a list of files with the same reviewer" to treating them as a
triple of (reviewers, files, directories). It does so using a dataclass
to make it easy to work with.

It also adds an EmitWarning convenience function, which will be more
heavily used in future CLs.

Bug: 389069356
Change-Id: I842d59ba69f5db5e3745fa39832794cdc1eb222e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6190430
Commit-Queue: Devon Loehr <dloehr@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
3 months ago
Alexander Cooper 682a6e1194 Add git cl squash-closed behavior
Introduces a new git cl command `squash-closed`. Similar to archive,
this will operate on all closed branches. Unlike archive, rather than
removing these branches and potentially leaving their downstreams in a
wedged state, this will squash the branch and appropriately reparent the
downstream. This makes this a good function to run in preparation of a
`git rebase-update`, especially if there are chained git branches, as
this will then shrink any merged branches to a single commit which
should cleanly apply and drop off.

Bug: 40264739
Change-Id: I1836f944d43f5f3dcebbebf06437bef890da96ca
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6230362
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Alexander Cooper <alcooper@chromium.org>
Auto-Submit: Alexander Cooper <alcooper@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Yiwei Zhang <yiwzhang@google.com>
3 months ago
recipe-roller c630492293 Roll recipe dependencies (trivial).
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/8723751718473694225

recipe_engine:
d7c6e2a03f
  d7c6e2a (chromium-autoroll@skia-public.iam.gserviceaccount.com)
      Roll CAS Client from 31b74d4b167d to 1c8dc8e37a49

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ie15f418f723d7bd86cf2d6374cdf87eb7e6ef1ae
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6235984
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
Alexander Cooper 380df04b62 Modify git squash-branch to perform reparenting
Bug: 40264739
Change-Id: I4ad7f4f8a670334b32c239458048e56c6af44098
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6227541
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Alexander Cooper <alcooper@chromium.org>
3 months ago
recipe-roller 569d698b0b Roll recipe dependencies (trivial).
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/8723823443286721969

recipe_engine:
9d24599642
  9d24599 (chromium-autoroll@skia-public.iam.gserviceaccount.com)
      Roll CAS Client from 8f3d9614016f to a9ef97b3c697

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I5fe46ef5a18d3a4a4973cc943b5f345285c85870
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6231591
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
Gary Tong cf5b6bd0cb Update message on how to format changes
Bug: 379902295
Change-Id: I6d4b2753664c20887f7063865536ce071252844d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6226155
Reviewed-by: Scott Lee <ddoman@chromium.org>
Auto-Submit: Gary Tong <gatong@chromium.org>
Commit-Queue: Scott Lee <ddoman@chromium.org>
3 months ago
recipe-roller 1545b061fd Roll recipe dependencies (trivial).
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/8723843576211635377

recipe_engine:
0d8a28f175
  0d8a28f (mohrr@google.com)
      [cipd] Add build_id metadata to pkg-register calls

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I09d9b6d0c617afde3c306f036504544fe52f1772
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6226156
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
Gennady Tsitovich 0d8b87d190 Fix cherry-picking in a non-git environment.
None was always passed to urlparse causing "Unable to determine host" error.

Bug: b/391547354
Change-Id: I58b63b4a33135952cae102e8446eea7cb3a82531
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6226685
Commit-Queue: Gennady Tsitovich <gtsitovich@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
3 months ago
recipe-roller 0cc30c3baf Roll recipe dependencies (trivial).
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/8723895164826249521

recipe_engine:
d42538c2b8
  d42538c (chromium-autoroll@skia-public.iam.gserviceaccount.com)
      Roll CAS Client from 8b72ae88ca2f to b408832fea90

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I55213b17585bf0befc7e4e967a443903c8832302
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6228600
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
Jordan Brown e42fac3e9c [dependency_metadata] Allow descriptions for CVEs
This adds a new way to report CVEs that includes an accompanying
description. It also adds a new validation check that ensures that the
CVE description is present for every entry listed in the 'Mitigated:'
field.

Bug: b/392026683
Change-Id: Ie55595970b49d705ac532f1f8c41ff47d959f56c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6211644
Auto-Submit: Jordan Brown <rop@google.com>
Reviewed-by: Jiewei Qian <qjw@chromium.org>
Commit-Queue: Jiewei Qian <qjw@chromium.org>
3 months ago
Anne Redulla b48765e850 [win-bootstrap] Remove git from CIPD manifest
Bug: b/360206460
Change-Id: I2d61a3b31cea92813fc2ceb6401dd9e70302c764
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6217700
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Anne Redulla <aredulla@google.com>
3 months ago
Anne Redulla 524abbc50e [win-bootstrap] Cleanup update_depot_tools.bat for lack of git-for-windows
Bug: b/360206460
Change-Id: I1a4d9ac8a4e0f19356e22bc15a664cc838e52cd3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6205947
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Anne Redulla <aredulla@google.com>
3 months ago
recipe-roller 35b602d7e0 Roll recipe dependencies (trivial).
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/8723926618605936577

recipe_engine:
a6004c9060
  a6004c9 (carverforbes@google.com)
      [tricium] Recognize .png files as binaries

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I775388ced1b4df3f50249e2e7933b69babd3de48
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6226763
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
recipe-roller 53d1a23b2f Roll recipe dependencies (trivial).
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/8723934800860209713

recipe_engine:
16b04d9612
  16b04d9 (mohrr@google.com)
      [cipd] Limit build_id metadata args

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I1c9161e1141b221ba8572576451a526e28adb1b1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6227159
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
Jordan Brown 98b7273c8d Add custom Mitigated field
This field stores a list of comma-separated CVE IDs that the dependency mitigates.

The field is validated to contain only valid CVE IDs.


Bug: b/392026683
Change-Id: I9578fc709086131695cfa7eee51e717c24440853
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6197756
Reviewed-by: Jiewei Qian <qjw@chromium.org>
Commit-Queue: Jordan Brown <rop@google.com>
3 months ago
recipe-roller f4ac21ad79 Roll recipe dependencies (trivial).
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/8724110961417401777

recipe_engine:
bf431e0f74
  bf431e0 (mohrr@google.com)
      [cipd] Don't add build_id metadata to pkg-build

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ic8f4e725686435907acbb8d224fe073a6595c12b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6222310
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
recipe-roller 6e2031a2dd Roll recipe dependencies (trivial).
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/8724188976874267745

recipe_engine:
e435120f35
  e435120 (mohrr@google.com)
      [cipd] Add 'build_id' metadata to every upload

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I4b2562f63ea6890942d3c9394a0cb9f1721269b7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6219646
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
Fumitoshi Ukai c88ad7af1a gn_helper: handle absolute path import
Bug: 393209409
Change-Id: Ic26b4502ab1744c7af7c0b06de2e4d1b9f2d3980
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6217699
Commit-Queue: Fumitoshi Ukai <ukai@google.com>
Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
Reviewed-by: Philipp Wollermann <philwo@google.com>
Auto-Submit: Fumitoshi Ukai <ukai@google.com>
Reviewed-by: Dirk Pranke <dpranke@google.com>
3 months ago
KS Yim 308ab0795e add github version of ytdevinfra config
It uses GitHub mirrow GoB. It also sets the custom vars.

R=yim@chromium.org

Bug:390703833
Change-Id: I5db6eadaeba04e6514fa0ff4e61d931690baac59
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6219827
Auto-Submit: K. S. Yim <yim@google.com>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Yiwei Zhang <yiwzhang@google.com>
3 months ago
Scott Lee c60f8194a5 lucicfg: format star files if --lucicfg
Bug: 390409288
Change-Id: Ida238f3a903c4f1dd31c8fa007e0a8823aeaf1aa
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6219826
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Scott Lee <ddoman@chromium.org>
3 months ago
Josip Sokcevic 9fd46c2b6b [presubmit] Check if .gitmodules diverges from DEPS
Raise presubmit error if .gitmodules file contains entry that doesn't
have gitlink, nor DEPS entry. This is desired as some tooling started to
depend on .gitmodules to learn about git dependencies.

Tested manually on chromium/src, based on the bug report test case.

R=ddoman@google.com

Bug: 392766700
Change-Id: I9dd8e03503b151f75e548acd0af098f342fc77a6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6219822
Reviewed-by: Scott Lee <ddoman@chromium.org>
Commit-Queue: Josip Sokcevic <sokcevic@chromium.org>
3 months ago
Matt Stark ce598256f2 Call use_siso_default_and_suggest_siso where possible.
Said function is defined in https://crrev.com/c/6217339.

Bug: 393209062

Change-Id: I1bced33272a6dd19d4e71f96f80ac6de61b48d9e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6217100
Reviewed-by: Junji Watanabe <jwata@google.com>
Commit-Queue: Matt Stark <msta@google.com>
3 months ago
recipe-roller b701d9c299 Roll recipe dependencies (trivial).
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/8724360733542160417

recipe_engine:
6132401d7c
  6132401 (chromium-autoroll@skia-public.iam.gserviceaccount.com)
      Roll CAS Client from be208752faa4 to c36fd1e86ba4

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I470a150bc72282b82725ca94669394023af182f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6216444
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
Matt Stark c40e9fe596 Only call _get_use_siso_default if use_siso wasn't explicitly set.
This allows us to configure the get_use_siso_default to give a notification suggesting people to switch.

Bug: 393209062

Change-Id: I1bced33272a6dd19d4e71f96f80ac6de61b48d9d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6217099
Commit-Queue: Matt Stark <msta@google.com>
Reviewed-by: Junji Watanabe <jwata@google.com>
3 months ago
Anne Redulla 9f48a4ca85 [win-bootstrap] Update docs for removal of git
Bug: b/360206460
Change-Id: I19da03909a082ac0414b751bf316600fa1bed403
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6205107
Commit-Queue: Anne Redulla <aredulla@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
3 months ago
Mohamed Heikal 03aad37858 Skip printing status if we CTRL-c out
No need to print status if the user interrupts the compile. Status is
always (all tasks done) since the remaining tasks will have been
canceled.

Change-Id: I3c4e5ff867cfd460aa357197f09276d128b00e01
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6207097
Reviewed-by: Andrew Grieve <agrieve@chromium.org>
Auto-Submit: Mohamed Heikal <mheikal@chromium.org>
Commit-Queue: Andrew Grieve <agrieve@chromium.org>
3 months ago
Josip Sokcevic dc2edc59f6 Remove check for canonical depot_tools URL
The check was originally introduced as part of svn -> git migration, and
no longer needed. This can use issues if user runs vendored depot_tools
inside chromium/src.

R=ddoman

Bug: 347356471
Change-Id: I1a082886933f23e1d7c53f2da906d0727c180a75
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6209088
Reviewed-by: Scott Lee <ddoman@chromium.org>
Commit-Queue: Josip Sokcevic <sokcevic@chromium.org>
3 months ago
Anne Redulla af7eadb024 [win-bootstrap] Remove git from bleeding edge CIPD manifest
Git is no longer installed by depot_tools (it should have been
installed directly). Thus, it can be removed from the bootstrap
manifest.

This CL applies the change to `manifest_bleeding_edge.txt`
first, to canary the change.

Bug: b/360206460
Change-Id: I78ced461bc68c33c9979668df1e275ccba6cd2e8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6205606
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Anne Redulla <aredulla@google.com>
3 months ago
recipe-roller f994d3d9fe Roll recipe dependencies (trivial).
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/8724540668924199185

recipe_engine:
de5f89e6bd
  de5f89e (chromium-autoroll@skia-public.iam.gserviceaccount.com)
      Roll CAS Client from 5371de300000 to 83f8c966f0ca

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I9f18085a65214370166d428f65c18676576b71b0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6204251
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
3 months ago
Dirk Pranke e1094f9eb9 Fix gclient config for the `website` project.
The website checkout doesn't have a `src` solution, so
use `website` instead.

Bug: 392668431
Change-Id: I4f488f01c4c63240a5df3f8553e6c637d1bbe9f2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6204242
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Commit-Queue: Dirk Pranke <dpranke@google.com>
3 months ago
Gavin Mak 77a800d729 Print branch name when running presubmits
This implements the proposed solution B in https://crbug.com/380877175#comment5
and will help distinguish presubmit results when working with stacked changes.

Bug: 380877175
Change-Id: I7f0807f7ce03109288976069c57c28488d6cadfd
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6196130
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 months ago
Scott Lee 8c858fc98c AIX: sys.platform always returns 'aix' instead of 'aix6' or 'aix7'.
sys.platform doesn't contain major version of aix.
Always return 'aix', instead of 'aix6' or 'aix7'.

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

Change-Id: I6d2075be808503731996df7bf17f23527ebdf445
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5999752
Commit-Queue: Scott Lee <ddoman@chromium.org>
Reviewed-by: Scott Lee <ddoman@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 months ago
Arthur Milchior d3717ed04d [Depot tools][Split]Clarify max depth
Looking at split’s documentation it was not clear what was the
behavior when the max-depth flag was missing. As it’s the default,
this seems like an important information. Especially when a warning
state to use it. Also, I thought the depth was counted starting from
the file, not the root. E.g. for file a/b/c/d/e.cc, the depth 1 would
mean using a/b/c/d/OWNERS, and not a/OWNERS. I believe that an example
would make it clearer to future users of LSC how to use this value.

Bug: None
Change-Id: I5d2b4f2fefceb8a4ec86ee1c508fb7848f69e44f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6179836
Auto-Submit: Arthur Milchior <arthurmilchior@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Arthur Milchior <arthurmilchior@chromium.org>
4 months ago
Gennady Tsitovich 45716abe5c Allow using `git cl cherry-pick` in a non-git environment.
This includes:
- adding `--host` parameter to `git-cl cherry-pick`
- adding `GetCommitMessage` to gerrit_util to be able to switch from `git show` used to get the commit message for a change

Bug: b/391547354
Change-Id: I9af227a78af5aaa1bdc98fc2520d98b413f0f3ed
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6180633
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Gennady Tsitovich <gtsitovich@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 months ago
Philipp Wollermann 49e10123de autoninja: Add workaround for slow reproxy starts
Somewhere deep in the Google Cloud Go SDK is a call to user.Current() to
get the user's home directory, in order to find some configuration files
necessary for TLS Client Certificate authentication.

The user.Current() function in Go versions prior to the yet unreleased
Go 1.24 can be very slow on Windows, as it causes a network call to the
Active Directory server to be made if the machine is part of a Windows
domain.

As we don't use TLS Client Certificate at Google, we can safely disable
this code path by setting GOOGLE_API_USE_CLIENT_CERTIFICATE=false in the
environment prior to launching reproxy and other tools using the SDK.

As I'm not sure whether this would cause issues for people actually
using TLS Client Certificate auth with their REAPI backend, let's only
apply this workaround on Google corp machines. It's highly unlikely that
others are affected by this particular issue anyway, and when Go 1.24
is released in February, it will fix the underlying issue anyway.

Bug: 388195531
Change-Id: Ia9d4b74c251b303b66b19fb59957ff5a922d883b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6191410
Auto-Submit: Philipp Wollermann <philwo@google.com>
Commit-Queue: Philipp Wollermann <philwo@google.com>
Reviewed-by: Fumitoshi Ukai <ukai@google.com>
4 months ago
Devon Loehr 36427aab02 split_cl: Always ask for confirmation before uploading
`git cl split` has the potential to do a lot of operations at once,
which is problematic if it didn't end up splitting things in a way
the user approves of. This changes it to print a summary of the
splitting, and asking the user to review it briefly before proceeding
with the upload.

Bug: 389069356, 40642562, 40269201
Change-Id: I90bead0147badbaa3afcce2264d805ae498f101c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6163905
Commit-Queue: Devon Loehr <dloehr@google.com>
Reviewed-by: Peter Kotwicz <pkotwicz@chromium.org>
Reviewed-by: Andy Perelson <ajp@google.com>
4 months ago
Jordan Brown a4131b9447 Silence WITH_PERMISSION_ONLY warnings
Currently using a license in the WITH_PERMISSION_ONLY list will create a
warning. By making an ALL_LICENSE list including this list and also
allowing it when checking for open source compatible licenses, it will
no longer create warnings.

This will enable us to change the current warnings into errors.

Bug: b/388620886
Change-Id: I883a3d3c825f0f1903b62d0b93810218b1f42bb9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6188501
Commit-Queue: Jordan Brown <rop@google.com>
Reviewed-by: Rachael Newitt <renewitt@google.com>
4 months ago
Allen Li 2b1cab2267 Uprev git-credential-luci
Picks up https://chromium-review.googlesource.com/c/infra/luci/luci-go/+/6071964

Bug: b/382341041
Change-Id: I2e668783d3f05e200655c59020ce492083763eef
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6082493
Commit-Queue: Allen Li <ayatane@chromium.org>
Reviewed-by: Vadim Shtayura <vadimsh@chromium.org>
4 months ago
Anne Redulla db9a0b01c2 [win-bootstrap] Exit with error if no Git in PATH
Bug: b/360206460
Change-Id: I5da52de0e050f4e6b9e484052d1e9ddacb79e8ad
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6171044
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Reviewed-by: Allen Li <ayatane@chromium.org>
Commit-Queue: Anne Redulla <aredulla@google.com>
4 months ago
Allen Li a2fcf8d776 [auth] Fix luci-auth reference in comment
Unfixed when we migrated Gerrit auth to git-credential-luci

Bug: b/342261857
Change-Id: I6660f03de830337b14b822a0245f6e0d18a58366
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6174308
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Allen Li <ayatane@chromium.org>
4 months ago
Allen Li 2d5461ae03 [auth] Clarify what account to use
There's some confusion on what account to use to login.  Add the
context for Gerrit to hopefully make it a bit easier to decide.

Bug: b/342261857
Change-Id: Ie59b156c2a91f8168bcd2f381f85fb8157040d80
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6178581
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Allen Li <ayatane@chromium.org>
4 months ago
recipe-roller 439380b2d0 Roll recipe dependencies (trivial).
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/8725094317015768769

recipe_engine:
5e43c98104
  5e43c98 (mohrr@google.com)
      [luci_config] Add annotations

Please check the following references for more information:
- autoroller, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#autoroller
- rollback, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/workflow.md#rollback
- cross-repo dependencies, https://chromium.googlesource.com/infra/luci/recipes-py/+/main/doc/cross_repo.md

Use https://goo.gl/noib3a to file a bug.

R=iannucci@chromium.org

Recipe-Tryjob-Bypass-Reason: Autoroller
Ignore-Freeze: Autoroller
Bugdroid-Send-Email: False
Change-Id: I60f4aa769cca8325d2fc4047025cb4836f3d3b8e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6188226
Bot-Commit: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
4 months ago
Allen Li 8eff9d233f [auth] Add test for overwriting global SSO rewrite rules
Sanity check for attached bug

Bug: b/390219533
Change-Id: I788e6beaa7f838568714b98b6f7923d455e6e3a4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6178580
Commit-Queue: Allen Li <ayatane@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
4 months ago
Allen Li 877b1e3cbd [auth] Hide global SSO rewrite in local repo
If the user uses SSO (and thus has SSO rewrite rules) for their global
config, a repo which locally uses an email that doesn't use SSO needs
an override.

Bug: b/390219533
Change-Id: I639dae4c1a45bbd2c17180855c22260979b0dbc2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6177780
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Allen Li <ayatane@chromium.org>
4 months ago