John Budorick | 334ff28 | 2018-11-21 23:18:33 | [diff] [blame] | 1 | # Using the trybots |
| 2 | |
| 3 | [TOC] |
| 4 | |
| 5 | ## Overview |
| 6 | |
| 7 | The trybots let committers try uncommitted patches on multiple platforms in |
| 8 | an automated way. |
| 9 | |
| 10 | - Trybots include all platforms for which we currently build Chromium, though |
| 11 | they may not support all configurations built on CI. |
| 12 | - The commit queue runs a subset of available trybots. See [here][1] for more |
| 13 | information. |
| 14 | - trybots can be manually invoked via `git cl try` or the "Choose Trybots" |
| 15 | UI in gerrit. |
| 16 | - Any committer can use the trybots. |
| 17 | - Non-committers with tryjob access can also use the trybots. See [here][2] |
| 18 | for more information. |
| 19 | - External contributors without tryjob access can ask committers to run |
| 20 | tryjobs for them. |
| 21 | |
Stephen Martinis | aad14f0 | 2021-10-05 20:31:26 | [diff] [blame^] | 22 | *** note |
| 23 | **Warning**: Please do not trigger more than ~5-10 tryjobs per builder per |
| 24 | hour. We don't have enough spare capacity for more than that, and we don't have |
| 25 | per-user quotas yet (https://crbug.com/1091070 to implement that). |
| 26 | *** |
| 27 | |
John Budorick | 334ff28 | 2018-11-21 23:18:33 | [diff] [blame] | 28 | ## Workflow |
| 29 | |
| 30 | 1. Upload your change to gerrit via `git cl upload` |
| 31 | 2. Run trybots: |
| 32 | |
| 33 | * Run the default set of trybots by starting a CQ dry run, either by |
| 34 | setting CQ+1 on gerrit or by running `git cl try` with no arguments. |
| 35 | * Run trybots of your choice by providing arguments to `git cl try`: |
| 36 | |
| 37 | * specify bucket name with `-B/--bucket`. For chromium tryjobs, this |
| 38 | should always be `luci.chromium.try` |
| 39 | * specify bot names with `-b/--bot`. This can be specified more than once. |
| 40 | |
| 41 | ### Examples |
| 42 | |
| 43 | Launching a CQ dry run: |
| 44 | |
| 45 | ```bash |
| 46 | $ git cl try |
| 47 | ``` |
| 48 | |
| 49 | Launching a particular trybot: |
| 50 | |
| 51 | ```bash |
Stephen Martinis | 089f5f0 | 2019-02-12 02:42:24 | [diff] [blame] | 52 | $ git cl try -B luci.chromium.try -b linux-rel |
John Budorick | 334ff28 | 2018-11-21 23:18:33 | [diff] [blame] | 53 | ``` |
| 54 | |
| 55 | Launching multiple trybots: |
| 56 | |
| 57 | ```bash |
| 58 | $ git cl try -B luci.chromium.try \ |
| 59 | -b android-binary-size \ |
| 60 | -b ios-simulator-full-configs \ |
| 61 | -b linux-blink-rel \ |
| 62 | -b win7-blink-rel |
| 63 | # etc |
| 64 | ``` |
| 65 | |
Robert Sesek | 823d8cf | 2020-07-28 20:27:59 | [diff] [blame] | 66 | ## Trying Changes in Dependencies |
| 67 | |
| 68 | It is also possible to run a Chromium try job with a pending CL in a separate |
| 69 | repository that is synced via DEPS. Normally DEPS files specify the SHA1 |
| 70 | revision hash of the dependency. But commits that are part of pending CLs are |
| 71 | not part of the default |
| 72 | [refspec](https://git-scm.com/book/en/v2/Git-Internals-The-Refspec) fetched when |
| 73 | gclient checks out the dependency. Instead, you can specify a symbolic reference |
| 74 | to your change, like `refs/changes/12/2277112/3`. To determine the ref to use, |
| 75 | click the "Download" button on the dependency CL in Gerrit, which will show it |
| 76 | as part of several git commands. Then edit the DEPS file in Chromium. |
| 77 | |
| 78 | If, for example, you wanted to test a pending V8 CL in Chromium, you would edit |
| 79 | the DEPS line, which may look like this: |
| 80 | |
| 81 | ``` |
| 82 | 'v8_revision': '50bc0b22b15da1410a1be6240a25a184d5896908', |
| 83 | ``` |
| 84 | |
| 85 | And change it to: |
| 86 | |
| 87 | ``` |
| 88 | 'v8_revision': 'refs/changes/12/2277112/3', |
| 89 | ``` |
| 90 | |
| 91 | When you run the try job, gclient will sync in your pending CL. Note that if |
| 92 | your pending CL is based on a revision that is either older or newer than the |
| 93 | revision specified in DEPS, the tryjob may fail. You can rebase your CL to be on |
| 94 | top of the same revision specified in the DEPS file to avoid this. |
| 95 | |
John Budorick | 334ff28 | 2018-11-21 23:18:33 | [diff] [blame] | 96 | ## Bugs? Feature requests? Questions? |
| 97 | |
| 98 | [File a trooper bug.][3] |
| 99 | |
| 100 | ## Legacy documentation |
| 101 | |
| 102 | - [Design doc][4] |
| 103 | |
| 104 | [1]: /docs/infra/cq.md |
| 105 | [2]: https://www.chromium.org/getting-involved/become-a-committer#TOC-Try-job-access |
| 106 | [3]: https://g.co/bugatrooper |
| 107 | [4]: https://www.chromium.org/developers/testing/try-server-usage/design |