https://source.chromium.org/chromium/chromium/tools/depot_tools/+/main:presubmit_support.py;l=319;drc=443d9135cc33f3156d5fe25ebec33f9adffbab65
This also makes any errors from `make train -C infra/bots`
look well formatted because check_output returns a bytestring
in Python3 and when that is printed, the newlines et al are not
rendered correctly. Thus we want the output of check_output
to be encoded to UTF-8.
Without setting the USE_PYTHON3 = True in PRESUBMIT.py,
it appears that `git cl upload` would try to run our
infra_tests.py in Python2 mode, which does not have
the encoding argument for check_output.
Apparently cipd_bin_packages/vpython3 does not have the
"six" package installed (but cipd_bin_packages/vpython does)
so I replaced the six.StringIO with io.StringIO, which
is where that is located in Python3.
Change-Id: Ic8f61bf943531583ba3d110a85260d69bdbf5eb2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/537677
Reviewed-by: Ravi Mistry <rmistry@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
Change-Id: Ia1d43e4814eb23fc111df0c1800425272337936c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/536639
Reviewed-by: Ravi Mistry <rmistry@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
A new RBE worker-pool called gce_linux was created in
conjunction with this CL. See
https://docs.google.com/document/d/14xMZCKews69SSTfULhE8HDUzT5XvPwZ4CvRufEvcZ74/edit#
for some details on that.
Note: everything under bazel/rbe/gce_linux was autogenerated
and can be ignored from manual review. It basically specifies
what files are on the RBE image that are necessary for running
Bazel.
Testing it out can be done by authenticating for RBE
gcloud auth application-default login --no-browser
Then, run make -C bazel rbe_known_good_builds
to test it out.
On my 4 core laptop with an empty local cache, but a
warm remote cache, the build took <2 min instead of the
10+ minutes it would have [1].
The folder structure in //bazel/rbe is meant to let us
have multiple remote configurations there, e.g.
//bazel/rbe/gce_windows.
Suggested Review Order:
- bazel/rbe/README.md
- bazel/rbe/gce_linux_container/Dockerfile to see the
bare-bones RBE image.
- bazel/rbe/BUILD.bazel to see a custom platform defined.
It is nearly identical to the autogenerated one
in bazel/rbe/gce_linux/config/BUILD, with one extra
field to force the gce_linux pool to be used.
- .bazelrc to see the settings needed to make
--config=linux-rbe work. The naming convention was
inspired by SkCMS's setup [2], and allows us to have
some common RBE settings (i.e. config:remote) and
some specialized ones for the given host machine
(e.g. config:linux-rbe) A very important, but subtle
configuration, is on line 86 of .bazelrc where we say
to use our hermetic toolchain and not whatever C++
compiler and headers are on the host machine (aka
the RBE container).
- toolchain/build_toolchain.bzl to see some additional
dependencies needed in the toolchain (to run IWYU) which
I had installed locally but didn't realize were important.
- third_party/BUILD.bazel to see an example of how failing
to specify all files can result in something that works
locally, but fails remotely.
--execution_log_json_file=/tmp/execlog.json helped debug
these issues.
- All other files.
[1] http://go/scrcast/NjM1ODE4MDI0NzM3MTc3Nnw3ODViZmFkMi1iOA
[2] https://skia.googlesource.com/skcms/+/30c8e303800c256febb03a09fdcda7f75d119b1b/.bazelrc#20
Change-Id: Ia0a9e6a06c1a13071949ab402dc5d897df6b12e1
Bug: skia:12541
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/524359
Reviewed-by: Leandro Lovisolo <lovisolo@google.com>
This is now done in SkCQ
Bug: skia:12487
Change-Id: I5a1414b7594ef371727c3391b18dbe6948b6c25a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/454457
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
This is now enforced using OWNERS
Change-Id: Iee0c639731376d7bc4c3deaa65ccadef3fae53f4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/445642
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
This work is being done by the skiastatus Gerrit plugin.
Bug: skia:12403
Change-Id: I42b81dcc9e2b4d5c99f9756eabed186f489a9adb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/445105
Commit-Queue: Ravi Mistry <rmistry@google.com>
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
This reverts commit 42d753031d.
Reason for revert: Replaced by the work in skbug.com/11824
Original change's description:
> Display a Docs-Preview link for each modified MD file
>
> Bug: skia:11824
> Change-Id: I6bd557affca5ccf9f2936d86e2b0da168ceb2670
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/390577
> Commit-Queue: Ravi Mistry <rmistry@google.com>
> Reviewed-by: Joe Gregorio <jcgregorio@google.com>
# Not skipping CQ checks because original CL landed > 1 day ago.
Bug: skia:11824
Change-Id: Ia874ed6474fcae4698cd676dbdf208dbdefdedc4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/399716
Reviewed-by: Ravi Mistry <rmistry@google.com>
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
This reverts commit 4ac25118b5.
Reason for revert: missing comma :|
Original change's description:
> make brianosman a public API owner
>
> ... and sort, and remove dead emails
>
> Change-Id: I0ef35918a5b4539559319c32b95109ca7c66f87c
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/365519
> Reviewed-by: Brian Osman <brianosman@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>
TBR=djsollen@google.com,mtklein@google.com,bsalomon@google.com,hcm@google.com,brianosman@google.com,reed@google.com
Change-Id: Ie3ac51c82c83e8b76fc3933f4f68938f608e32d5
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/365507
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
... and sort, and remove dead emails
Change-Id: I0ef35918a5b4539559319c32b95109ca7c66f87c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/365519
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Errors will be reported like this:
"""""""""
Running presubmit upload checks ...
** Presubmit ERRORS **
Git conflict markers found in whitespace.txt:14 <<<<<<< HEAD
Git conflict markers found in whitespace.txt:16 =======
Git conflict markers found in whitespace.txt:18 >>>>>>> 75a85179504e59df7b3abbc09113f24f2233001b
"""""""""
Bug: skia:11098
Change-Id: I24f90ec545b797f1d782a1733b8273ce176b1012
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/345037
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
This reverts commit 540b51ce8f.
Reason for revert: RPI disk space
Original change's description:
> Reland "[infra] Switch from isolate to RBE-CAS"
>
> Bug: skia:10883
> Change-Id: Iec82a07fdf3c0807a9bb1870309eded85d4f0b1e
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/341679
> Commit-Queue: Eric Boren <borenet@google.com>
> Reviewed-by: Weston Tracey <westont@google.com>
TBR=borenet@google.com,westont@google.com
Change-Id: I0156842b995d275d8deb5bd73c6877de7f8af72e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:10883
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/342596
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
Golden SkSL outputs are intended to eventually replace the majority of
our unit tests, since they can automatically update themselves when we
change implementation details of the compiler.
If you change the compiler output without updating the Golden files, the
CheckGeneratedFiles housekeeper will be triggered. Set
`skia_compile_processors` or `skia_compile_sksl_tests` to true in your
GN args to regenerate them.
Almost all of the tests from SkSLFPTests.cpp and SkSLGLSLTests.cpp can
be migrated into separate unit-test .fp/.sksl files in a followup CL.
hcm@ has signed off on removing the copyright boilerplate preamble from
our unit test files.
Change-Id: I9e24a944bbac8f8efd62c92481b022a0b1ecdd0b
Bug: skia:10694
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/316336
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Change-Id: I78eff440486eb2e76acdbd8a43c6c99cf6ed9bbb
Bug: chromium:1064305
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/282276
Commit-Queue: Eric Boren <borenet@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
The CheckGeneratedFiles bot only required rewriting
.gn files, while the presubmit wants both .gn and .gni files.
It also appears that the #includes rewrite script runs on
both the presubmit and CheckGeneratedFiles bots.
These presubmits run on the CQ before landing right?
If so, no need for them in the CheckGeneratedFIles bot at all.
And of course, format .gni files.
Change-Id: Icd4526d62f85088862ad93566cc9ace11dc3e33f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/281505
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
* Mainly updates to documentation.
* Fix some comments in PRESUBMIT.py.
* Delete tools/lua/trigger_ct_lua. It has not worked in many years.
Bug: skia:9962
Change-Id: If6f58f173f2c8bd3fc9bdfc4db440f42489fee08
Docs-Preview: https://skia.org/?cl=274597
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/274597
Commit-Queue: Ravi Mistry <rmistry@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
I think this fixes issues with `git cl upload` on Windows machines.
Note that fetch-gn grabs gn.exe (not gn.bat).
Change-Id: Iba64ec62cce00e8ba0076ce83d47e4e6e6ef6197
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/271604
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Change-Id: I3f2f3713fc27207c26d02c29358cd582440e8e65
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/271037
Commit-Queue: Eric Boren <borenet@google.com>
Auto-Submit: Ben Wagner aka dogben <benjaminwagner@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
Change-Id: I649f07e036f184e6dbb3a335bdd979dedea27ec8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270876
Commit-Queue: Eric Boren <borenet@google.com>
Auto-Submit: Ben Wagner aka dogben <benjaminwagner@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
change.AddDescriptionFooters() doesn't exist, the right function is
change.AddDescriptionFooter()
Bug: 1042324
Change-Id: Icb417eab494dc217bc8bb9a51810f9cf65cce828
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/268667
Auto-Submit: Edward Lemur <ehmaldonado@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
Change-Id: I10f9083ebda6038026cbc322b07528a4da820634
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266858
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
The CQ handles tree closure,
and these {dm,nanobench}_flags.py files don't exist.
Change-Id: I19b5842763efd121a2bf7c3ff9075bf46089d74a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/264342
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
This might be nice as an early reminder that you'll need special review,
and ought to let us not have to re-run this (~1m) PRESUBMIT bot on CQ+2.
Change-Id: I94c370d3cfcf7b593961fcaf3907e0a045ff1c89
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/264336
Reviewed-by: Eric Boren <borenet@google.com>
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
urllib_request was introduced in crrev.com/c/1866170 to add
python 3 compatibility.
Bug: 1009814
Change-Id: Iecc246d4f251983051bd0cf812903831ea7e0c2d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/249588
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
Also:
Revert "don't try to format includes on windows"
This reverts commit e68b5bd4e6.
Change-Id: I93dc4dba4808c07882e977ac0693c93e282bbad5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/230878
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
It's not going to work:
- windows\style\paths don't work well in Python
- something seems to be slipping in extra \r, probably print?
Change-Id: I6d9a0cc0bff403b9b45412b0e92290a9346bcf14
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/230641
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Let's spin this off in case (dare I say it) the other CL is reverted.
Change-Id: I8ae978cd82772b418f7aae5a64cc8c0fd066ddb9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/230443
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
You can now pass files to rewrite, still defaulting
to all sources. This speeds things up and is nice
for a Git or PRESUBMIT hook, added here too.
Passing --dry-run or -n will just check that the
files we would have written is the same, printing
the names of any mismatches and failing if any.
Cq-Include-Trybots: skia.primary:Housekeeper-PerCommit-CheckGeneratedFiles
Tricium: no
Change-Id: I94218f49071b8634841b04e4b536ad1ae5d9d5fd
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/230143
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
Branches and tags may change out from under us or disappear entirely.
Also add a presubmit check to prevent regressing.
Change-Id: I73878907d9a72f7de7b50989919c3a7bc385abf9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/229490
Reviewed-by: Ben Wagner aka dogben <benjaminwagner@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
Change-Id: I084645a46feda183747e9d7fc3b40b1aa56c5f78
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/211103
Commit-Queue: Eric Boren <borenet@google.com>
Reviewed-by: Ben Wagner aka dogben <benjaminwagner@google.com>
Change-Id: Ic6f86f615d046b7afdc8bd2fe21d76024d800613
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/205348
Commit-Queue: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Bug: skia:
Change-Id: I03e5ceff326d38f96ce6fea699248b0232e39a63
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/202701
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
Tricium is now doing this for us; no need to block uploads on this
(sometimes extremely slow) check.
Bug: skia:8209
Change-Id: Ib0f672c1a40c6dfabb53d32fb4f87f8d201136d2
Reviewed-on: https://skia-review.googlesource.com/c/183680
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
We will use path_regexes in the future in cq.cfg if required.
NoTry: true
Bug: skia:8542
Change-Id: Icdba5d3beee6e8b58a9b070b4db8c66cc8f71ac0
Reviewed-on: https://skia-review.googlesource.com/c/170355
Commit-Queue: Ravi Mistry <rmistry@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
Bug: skia:8291
Change-Id: I4a0f8396fd1a195414f618c74a3eb46a3956af70
Reviewed-on: https://skia-review.googlesource.com/152740
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
The canned CR and trailing whitespace presubmit checks only emit
warnings, so no one pays any attention to them and they don't fail the
build. All trailing whitespace was removed recently, and it has already
returned. This makes these checks actual errors so they will fail the
presubmit check on the bots, so that they will actually be seen.
Change-Id: I5d774ae45a68b8eb881548d0158c37a8f5fe052e
Reviewed-on: https://skia-review.googlesource.com/59164
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>