With this CL, build time of chrome with non-cache hit case improved a
bit on P620 Linux workstation.
```
Benchmark 1: RBE_local_resource_fraction=0.4 RBE_racing_bias=0.7 RBE_remote_accept_cache=false autoninja -C out/Default chrome
Time (mean ± σ): 337.697 s ± 11.439 s [User: 3086.301 s, System: 1362.952 s]
Range (min … max): 327.732 s … 351.680 s 5 runs
```
```
Benchmark 1: RBE_remote_accept_cache=false autoninja -C out/Default chrome
Time (mean ± σ): 347.795 s ± 15.906 s [User: 2764.181 s, System: 1199.244 s]
Range (min … max): 331.964 s … 367.898 s 5 runs
```
Bug: 352463976
Change-Id: Ic9732583857ce175888a7ec65cf9e323529f0a07
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5693250
Commit-Queue: Takuto Ikuta <tikuta@chromium.org>
Reviewed-by: Junji Watanabe <jwata@google.com>
Auto-Submit: Takuto Ikuta <tikuta@chromium.org>
Can be used to remove config changes. Not called yet.
There's some logic duplication, will try to clean up later.
Bug: b/351024645
Change-Id: Ibdda4b93e600efc4b84240374e58478e2cc1501a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5693419
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Allen Li <ayatane@chromium.org>
I'm planning on adding removal for all of these, so sectioning
everything out.
Change-Id: Ieb4369a267dff323cd644cff00d98761800a8a90
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5691995
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Allen Li <ayatane@chromium.org>
Potentially makes it easier to test (needs more deps extracted and
injected though).
Change-Id: I3a300264f85f4420d8b41a7cd1155e38341638f5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5689683
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Allen Li <ayatane@chromium.org>
Potentially makes it easier to test (needs more deps extracted and
injected though).
Change-Id: I8c551b39c97ec95291995e614c760073b10a4615
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5689682
Commit-Queue: Allen Li <ayatane@chromium.org>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
NoReturn applies to functions that never return. Doesn't make sense
to return None or NoReturn.
Change-Id: I1f1a759999a8dad1c2b2a7fd9623e3ea5216c726
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5688607
Auto-Submit: Allen Li <ayatane@chromium.org>
Commit-Queue: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Allen Li <ayatane@chromium.org>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
This permit downstream clients to retrieve the "source" text and do
their own formatting instead of relying on the format coded in
get_message().
Change-Id: Ia36cbd064ed0781bda76b09b064b97f6dc5e899e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5686730
Commit-Queue: Jiewei Qian <qjw@chromium.org>
Reviewed-by: Anne Redulla <aredulla@google.com>
Scopes needs to be passed as a single CLI argument
Bug: b/351046856
Change-Id: I1c0e78b9bfa9997af3466f5b54ae27a535fa7488
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5689095
Commit-Queue: Yiwei Zhang <yiwzhang@google.com>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Auto-Submit: Allen Li <ayatane@chromium.org>
This will replace the user consent logics in ninjalog_uploader_wrapper.py and reclient_metrics.py
See also https://crrev.com/c/5669094 for how this will be used.
Bug: 345113094
Change-Id: Iffc4975c152ba63f7577c09e5254c499fe8973c0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5671052
Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Reviewed-by: Fumitoshi Ukai <ukai@google.com>
Auto-Submit: Junji Watanabe <jwata@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@chromium.org>
- Remove reclient_helper.py to avoid calling it directly.
- Cleans up autoninja.py
I just want to do this cleanup before merging the user notice messages
for logs/metrics collection.
Bug: 345113094
Change-Id: I0c76426b3cb387eae6dede031727c107e57d5d1a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5668282
Reviewed-by: Philipp Wollermann <philwo@google.com>
Reviewed-by: Fumitoshi Ukai <ukai@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@chromium.org>
Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
Reviewed-by: Ben Segall <bentekkie@google.com>
Auto-Submit: Junji Watanabe <jwata@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
In nosquash mode, `git cl` is pretty challenging to use since we don't
have issue numbers. All three parts of the triplet id are readily
available though. This CL adds a fallback to `git cl` which looks up the
issue number by getting the change details by triplet_id.
Change-Id: I0839fe75bcb4bc8d60ff36b4da26dc0e419a1493
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5633186
Commit-Queue: Daniel Rubery <drubery@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Change-Id: I575b91f6b6e28ac58160e3c0fc59398df222b150
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5677608
Auto-Submit: Allen Li <ayatane@chromium.org>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Allen Li <ayatane@chromium.org>
Commit-Queue: Yiwei Zhang <yiwzhang@google.com>
This script allows squashing a branch and all of its downstream
branches in one command.
This is useful for squashing stacked branches that have a lot of
commits each just before using `git rebase-update`, as this is
highly likely to run into a lot of rebase conflicts, repeatedly.
This should only be used if the user is okay with losing their
git commit history.
Change-Id: Id28a941d898def73f785d791499c7ee0784e0136
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5659262
Reviewed-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
Commit-Queue: Patrick Monette <pmonette@chromium.org>
Because running git cl creds-check in every single repo is poor UX for
early dogfooders.
Bug: b/348024314
Change-Id: Ib5641418de7fa5a55a7f67b7069e63c04403852a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5660338
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Allen Li <ayatane@chromium.org>
Running `git cl creds-check` without any credentials will show:
```
Your .gitcookies have credentials for these hosts:
No Git/Gerrit credentials found
```
The first line of the output should not assume that there are hosts. Don't show this line if credentials are not found.
Change-Id: Ie6eba3518f4b270eef5fbe0c51b4494762a3aef4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5663779
Reviewed-by: Scott Lee <ddoman@chromium.org>
Auto-Submit: Gavin Mak <gavinmak@google.com>
Commit-Queue: Scott Lee <ddoman@chromium.org>
Instead of just telling users their credentials are missing, link them to the new password URL so they can fix it.
Change-Id: I9559868ae948e6d18cef1205083aee0ad5c2489a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5665862
Commit-Queue: Joanna Wang <jojwang@chromium.org>
Auto-Submit: Gavin Mak <gavinmak@google.com>
Reviewed-by: Joanna Wang <jojwang@chromium.org>
Basically there are lots of different formats for everything and
certain things need things in different formats.
Credential helper needs whatever remote the user has configured (which
may or may not have `-review`).
Checking ShouldUseSSO needs the Gerrit host with `-review`.
SSO URL needs the short name (not FQDN), and without `-review`. I
think.
Anyway, this should work now. Probably.
Bug: b/348024314
Change-Id: I495686ecfff43c61fe78d72ccd485bc93388e036
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5662256
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Allen Li <ayatane@chromium.org>
Because we need to dynamically determine whether to use SSO.
Bug: b/348024314
Change-Id: I5ac768f1e0c20254b4cfd4815270ee4e2b9a5544
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5660884
Reviewed-by: Yiwei Zhang <yiwzhang@google.com>
Commit-Queue: Allen Li <ayatane@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
I often find myself working on stacked changes, and this option will
make it easier to integrate changes into downstream CLs.
With `git rebase-update --current --tree --no-fetch`, it is possible
to only rebase the current chain of changes, without touching any other
local branches that may exist.
This is beneficial both for speed, and to avoid having to resolve merge
conflicts on branches unrelated to the changes you are currently working
on.
Change-Id: I2d3853ad5aad6c74db0ae26ff8d27d14dcaed3e2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5546383
Auto-Submit: Peter Pakkenberg <pbirk@chromium.org>
Commit-Queue: Scott Lee <ddoman@chromium.org>
Reviewed-by: Scott Lee <ddoman@chromium.org>