1cb93a386Sopenharmony_ci---
2cb93a386Sopenharmony_cititle: 'Skia Gardener Documentation'
3cb93a386Sopenharmony_cilinkTitle: 'Skia Gardener Documentation'
4cb93a386Sopenharmony_ci
5cb93a386Sopenharmony_ciweight: 8
6cb93a386Sopenharmony_ci---
7cb93a386Sopenharmony_ci
8cb93a386Sopenharmony_ci### Contents
9cb93a386Sopenharmony_ci
10cb93a386Sopenharmony_ci- [What does a Skia Gardener do?](#what_is_a_skia_gardener)
11cb93a386Sopenharmony_ci  - [Skia tree](#skia_tree)
12cb93a386Sopenharmony_ci  - [Triage](#triage)
13cb93a386Sopenharmony_ci  - [Blamer](#blamer)
14cb93a386Sopenharmony_ci  - [AutoRollers](#autorollers)
15cb93a386Sopenharmony_ci  - [Gold and Perf](#gold_and_perf)
16cb93a386Sopenharmony_ci  - [Documentation](#skia_gardener_doc)
17cb93a386Sopenharmony_ci- [Preparing for your rotation](#preparations)
18cb93a386Sopenharmony_ci  - [Useful bookmarks](#useful_bookmarks)
19cb93a386Sopenharmony_ci  - [Chat rooms](#chat_rooms)
20cb93a386Sopenharmony_ci- [View current and upcoming rotations](#view_current_upcoming_rotations)
21cb93a386Sopenharmony_ci- [How to swap rotation shifts](#how_to_swap)
22cb93a386Sopenharmony_ci- [Tips for Skia Gardeners](#tips)
23cb93a386Sopenharmony_ci  - [When to file bugs](#when_to_file_bugs)
24cb93a386Sopenharmony_ci  - [How to close or re-open the tree](#how_close_tree)
25cb93a386Sopenharmony_ci  - [How to revert a CL](#how_to_revert)
26cb93a386Sopenharmony_ci  - [What to do if DEPS roll fails to land](#deps_roll_failures)
27cb93a386Sopenharmony_ci  - [How to rebaseline](#how_to_rebaseline)
28cb93a386Sopenharmony_ci
29cb93a386Sopenharmony_ci<a name="what_is_a_skia_gardener"></a>
30cb93a386Sopenharmony_ci
31cb93a386Sopenharmony_ci## What does a Skia Gardener do?
32cb93a386Sopenharmony_ci
33cb93a386Sopenharmony_ci---
34cb93a386Sopenharmony_ci
35cb93a386Sopenharmony_ciA Skia Gardener keeps an eye on the tree, DEPS rolls, Gold tool, the Perf tool,
36cb93a386Sopenharmony_ciand triages Chrome bugs.
37cb93a386Sopenharmony_ci
38cb93a386Sopenharmony_ciBelow is a brief summary of what the gardener does for each task:
39cb93a386Sopenharmony_ci
40cb93a386Sopenharmony_ci<a name="skia_tree"></a>
41cb93a386Sopenharmony_ci
42cb93a386Sopenharmony_ci### Skia tree
43cb93a386Sopenharmony_ci
44cb93a386Sopenharmony_ci- Understand the
45cb93a386Sopenharmony_ci  [testing infrastructure](https://skia.org/docs/dev/testing/automated_testing).
46cb93a386Sopenharmony_ci- Start watching the [status page](https://status.skia.org) for bot breakages.
47cb93a386Sopenharmony_ci- Track down people responsible for breakages and revert broken changes if there
48cb93a386Sopenharmony_ci  is no easy fix. You can use [blamer](#blamer) to help track down such changes.
49cb93a386Sopenharmony_ci   - For clean reverts, you need to add "Rubber Stamper" if the author isn't around to +1
50cb93a386Sopenharmony_ci     the change. See [go/rubber-stamper-user-guide](http://go/rubber-stamper-user-guide) for more.
51cb93a386Sopenharmony_ci   - For dirty reverts, you can use [go/skia-break-glass](http://go/skia-break-glass) to
52cb93a386Sopenharmony_ci     move quickly.
53cb93a386Sopenharmony_ci- Close and open the [tree](http://tree-status.skia.org).
54cb93a386Sopenharmony_ci- Keep the builder comments on the [status page](https://status.skia.org) up to
55cb93a386Sopenharmony_ci  date.
56cb93a386Sopenharmony_ci- File or follow up with
57cb93a386Sopenharmony_ci  [BreakingTheBuildbots bugs](https://bugs.chromium.org/p/skia/issues/list?q=label:BreakingTheBuildbots).
58cb93a386Sopenharmony_ci  See the tip on [when to file bugs](#when_to_file_bugs).
59cb93a386Sopenharmony_ci- Read and update the
60cb93a386Sopenharmony_ci  [Ongoing Issues section](https://docs.google.com/document/d/1y2jUf4vXI0fwhu2TiCLVIfWC1JOxFcHXGw39y7i-y_I/edit#heading=h.tpualuc3p7z0)
61cb93a386Sopenharmony_ci  in the handoff doc.
62cb93a386Sopenharmony_ci- (Optional) Document significant events that occurred during your shift in the
63cb93a386Sopenharmony_ci  [Weekly Handoff Notes section](https://docs.google.com/document/d/1y2jUf4vXI0fwhu2TiCLVIfWC1JOxFcHXGw39y7i-y_I/edit#heading=h.y49irwbutzr)
64cb93a386Sopenharmony_ci  in the handoff doc.
65cb93a386Sopenharmony_ci
66cb93a386Sopenharmony_ci<a name="triage"></a>
67cb93a386Sopenharmony_ci
68cb93a386Sopenharmony_ci### Triage
69cb93a386Sopenharmony_ci
70cb93a386Sopenharmony_ciYou should triage Chromium and Skia bugs that show up under "Untriaged Bugs" on
71cb93a386Sopenharmony_cithe [status page](https://status.skia.org). The Android Gardener will triage the
72cb93a386Sopenharmony_ciuntriaged Android Bugs. For a more detailed view of bugs see
73cb93a386Sopenharmony_ci[Skia Bugs Central](https://bugs-central.skia.org/).
74cb93a386Sopenharmony_ci
75cb93a386Sopenharmony_ci<a name="blamer"></a>
76cb93a386Sopenharmony_ci
77cb93a386Sopenharmony_ci### Blamer
78cb93a386Sopenharmony_ci
79cb93a386Sopenharmony_ciIf you have Go installed, a command-line tool is available to search through git
80cb93a386Sopenharmony_cihistory and do text searches on the full patch text and the commit message. To
81cb93a386Sopenharmony_ciinstall blamer run:
82cb93a386Sopenharmony_ci
83cb93a386Sopenharmony_ci    go get go.skia.org/infra/blamer/go/blamer
84cb93a386Sopenharmony_ci
85cb93a386Sopenharmony_ciThen run blamer from within a Skia checkout. For example, to search if the
86cb93a386Sopenharmony_cistring "SkDevice" has appeared in the last 10 commits:
87cb93a386Sopenharmony_ci
88cb93a386Sopenharmony_ci    $ $GOPATH/bin/blamer --match SkDevice --num 10
89cb93a386Sopenharmony_ci
90cb93a386Sopenharmony_ci    commit ea70c4bb22394c8dcc29a369d3422a2b8f3b3e80
91cb93a386Sopenharmony_ci    Author: robertphillips <robertphillips@google.com>
92cb93a386Sopenharmony_ci    Date:   Wed Jul 20 08:54:31 2016 -0700
93cb93a386Sopenharmony_ci
94cb93a386Sopenharmony_ci        Remove SkDevice::accessRenderTarget virtual
95cb93a386Sopenharmony_ci        GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2167723002
96cb93a386Sopenharmony_ci
97cb93a386Sopenharmony_ci        Review-Url: https://codereview.chromium.org/2167723002
98cb93a386Sopenharmony_ci
99cb93a386Sopenharmony_ci<a name="autorollers"></a>
100cb93a386Sopenharmony_ci
101cb93a386Sopenharmony_ci### Autorollers
102cb93a386Sopenharmony_ci
103cb93a386Sopenharmony_ci- Ensure that all AutoRollers listed on the
104cb93a386Sopenharmony_ci  [status page](https://status.skia.org) are successfully landing.
105cb93a386Sopenharmony_ci
106cb93a386Sopenharmony_ci<a name="gold_and_perf"></a>
107cb93a386Sopenharmony_ci
108cb93a386Sopenharmony_ci### Gold and Perf
109cb93a386Sopenharmony_ci
110cb93a386Sopenharmony_ci- Pay attention for new [Perf](https://perf.skia.org/) and
111cb93a386Sopenharmony_ci  [Gold](https://gold.skia.org/) alerts (by clicking on the bell at the top
112cb93a386Sopenharmony_ci  right of the [status page](https://status.skia.org)).
113cb93a386Sopenharmony_ci- The gardener's duty here is to make sure that when developers introduce new
114cb93a386Sopenharmony_ci  images or new perf regressions, that they are aware of what happened, and they
115cb93a386Sopenharmony_ci  use these tools to take appropriate action.
116cb93a386Sopenharmony_ci
117cb93a386Sopenharmony_ci<a name="skia_gardener_doc"></a>
118cb93a386Sopenharmony_ci
119cb93a386Sopenharmony_ci### Documentation
120cb93a386Sopenharmony_ci
121cb93a386Sopenharmony_ci- Improve/update this documentation page for future gardeners, especially the
122cb93a386Sopenharmony_ci  [Tips section](#tips).
123cb93a386Sopenharmony_ci
124cb93a386Sopenharmony_ciIn general, gardeners should have a strong bias towards actions that keep the
125cb93a386Sopenharmony_citree green and then open; if a simple revert can fix the problem, the gardener
126cb93a386Sopenharmony_ci<b>should revert first and ask questions later</b>.
127cb93a386Sopenharmony_ci
128cb93a386Sopenharmony_ci<a name="preparations"></a>
129cb93a386Sopenharmony_ci
130cb93a386Sopenharmony_ci## Preparing for your rotation
131cb93a386Sopenharmony_ci
132cb93a386Sopenharmony_ci---
133cb93a386Sopenharmony_ci
134cb93a386Sopenharmony_ci<a name="useful_bookmarks"></a>
135cb93a386Sopenharmony_ci
136cb93a386Sopenharmony_ci### Useful bookmarks
137cb93a386Sopenharmony_ci
138cb93a386Sopenharmony_ci- [The Chromium main console](https://ci.chromium.org/p/chromium/g/main/console).
139cb93a386Sopenharmony_ci- [The Flutter engine console](https://ci.chromium.org/p/flutter/g/engine/console).
140cb93a386Sopenharmony_ci- [Skia client search](https://brianosman.users.x20web.corp.google.com/www/skia-client-search.html),
141cb93a386Sopenharmony_ci  a tool for searching the codebases of all skia clients at once.
142cb93a386Sopenharmony_ci
143cb93a386Sopenharmony_ci<a name="chat_rooms"></a>
144cb93a386Sopenharmony_ci
145cb93a386Sopenharmony_ci### Chat rooms
146cb93a386Sopenharmony_ci
147cb93a386Sopenharmony_ci- [Flutter Engine Sherriff](https://chat.google.com/room/AAAAm69vf-M) room to
148cb93a386Sopenharmony_ci  watch for Flutter issues that are caused by Skia bugs or need assistance from
149cb93a386Sopenharmony_ci  our team.
150cb93a386Sopenharmony_ci
151cb93a386Sopenharmony_ci<a name="view_current_upcoming_rotations"></a>
152cb93a386Sopenharmony_ci
153cb93a386Sopenharmony_ci## View current and upcoming rotations
154cb93a386Sopenharmony_ci
155cb93a386Sopenharmony_ci---
156cb93a386Sopenharmony_ci
157cb93a386Sopenharmony_ciThe list of Skia Gardeners is specified
158cb93a386Sopenharmony_ci[here](https://rotations.corp.google.com/rotation/4699606003744768). The
159cb93a386Sopenharmony_cigardeners widget on the [status page](https://status.skia.org) also displays the
160cb93a386Sopenharmony_cicurrent gardeners.
161cb93a386Sopenharmony_ci
162cb93a386Sopenharmony_ci<a name="how_to_swap"></a>
163cb93a386Sopenharmony_ci
164cb93a386Sopenharmony_ci## How to swap rotation shifts
165cb93a386Sopenharmony_ci
166cb93a386Sopenharmony_ci---
167cb93a386Sopenharmony_ci
168cb93a386Sopenharmony_ciIf you need to swap shifts with someone (because you are out sick or on
169cb93a386Sopenharmony_civacation), please get approval from the person you want to swap with and
170cb93a386Sopenharmony_cidirectly make the swap via the
171cb93a386Sopenharmony_ci[rotations page](https://rotations.corp.google.com/rotation/4699606003744768).
172cb93a386Sopenharmony_ci
173cb93a386Sopenharmony_ci<a name="tips"></a>
174cb93a386Sopenharmony_ci
175cb93a386Sopenharmony_ci## Tips for Skia Gardeners
176cb93a386Sopenharmony_ci
177cb93a386Sopenharmony_ci---
178cb93a386Sopenharmony_ci
179cb93a386Sopenharmony_ci<a name="when_to_file_bugs"></a>
180cb93a386Sopenharmony_ci
181cb93a386Sopenharmony_ci### When to file bugs
182cb93a386Sopenharmony_ci
183cb93a386Sopenharmony_ciPay close attention to the "Failures" view in the
184cb93a386Sopenharmony_ci[status page](https://status.skia.org). Look at all existing
185cb93a386Sopenharmony_ci[BreakingTheBuildbots bugs](https://bug.skia.org/?q=label:BreakingTheBuildbots).
186cb93a386Sopenharmony_ciIf the list is kept up to date then it should accurately represent everything
187cb93a386Sopenharmony_cithat is causing failures. If it does not, then please file/update bugs
188cb93a386Sopenharmony_ciaccordingly.
189cb93a386Sopenharmony_ci
190cb93a386Sopenharmony_ci<a name="how_close_tree"></a>
191cb93a386Sopenharmony_ci
192cb93a386Sopenharmony_ci### How to close or re-open the tree
193cb93a386Sopenharmony_ci
194cb93a386Sopenharmony_ci1. Go to [tree-status.skia.org](https://tree-status.skia.org).
195cb93a386Sopenharmony_ci2. Change the status.
196cb93a386Sopenharmony_ci
197cb93a386Sopenharmony_ci- To close the tree, include the word "closed" in the status.
198cb93a386Sopenharmony_ci- To open the tree, include the word "open" in the status.
199cb93a386Sopenharmony_ci- To caution the tree, include the word "caution" in the status.
200cb93a386Sopenharmony_ci
201cb93a386Sopenharmony_ci<a name="how_to_submit_when_tree_closed"></a>
202cb93a386Sopenharmony_ci
203cb93a386Sopenharmony_ci### How to submit when the tree is closed
204cb93a386Sopenharmony_ci
205cb93a386Sopenharmony_ci- Submit manually using the "git cl land" with the --bypass-hooks flag.
206cb93a386Sopenharmony_ci- Add "No-Tree-Checks: true" to your CL description and use the CQ as usual.
207cb93a386Sopenharmony_ci
208cb93a386Sopenharmony_ci<a name="how_to_revert"></a>
209cb93a386Sopenharmony_ci
210cb93a386Sopenharmony_ci### How to revert a CL
211cb93a386Sopenharmony_ci
212cb93a386Sopenharmony_ciSee the revert documentation [here](https://skia.org/docs/dev/contrib/revert).
213cb93a386Sopenharmony_ci
214cb93a386Sopenharmony_ci<a name="deps_roll_failures"></a>
215cb93a386Sopenharmony_ci
216cb93a386Sopenharmony_ci### What to do if DEPS roll fails to land
217cb93a386Sopenharmony_ci
218cb93a386Sopenharmony_ciA common cause of DEPS roll failures are layout tests. Find the offending Skia
219cb93a386Sopenharmony_ciCL by examining the commit hash range in the DEPS roll and revert (or talk to
220cb93a386Sopenharmony_cithe commit author if they are available). If you do revert then keep an eye on
221cb93a386Sopenharmony_cithe next DEPS roll to make sure it succeeds.
222cb93a386Sopenharmony_ci
223cb93a386Sopenharmony_ciIf a Skia CL changes layout tests, but the new images look good, the tests need
224cb93a386Sopenharmony_cito be rebaselined. See [Rebaseline Layout Tests](#how_to_rebaseline).
225cb93a386Sopenharmony_ci
226cb93a386Sopenharmony_ci<a name="how_to_rebaseline"></a>
227cb93a386Sopenharmony_ci
228cb93a386Sopenharmony_ci### Rebaseline Layout Tests (i.e., add suppressions)
229cb93a386Sopenharmony_ci
230cb93a386Sopenharmony_ci- First create a Chromium bug:
231cb93a386Sopenharmony_ci
232cb93a386Sopenharmony_ci  - goto [crbug.com](https://crbug.com)
233cb93a386Sopenharmony_ci  - Make sure you're logged in with your Chromium credentials
234cb93a386Sopenharmony_ci  - Click “New Issue”
235cb93a386Sopenharmony_ci  - Summary: “Skia image rebaseline”
236cb93a386Sopenharmony_ci  - Description:
237cb93a386Sopenharmony_ci    - DEPS roll #,
238cb93a386Sopenharmony_ci    - Helpful message about what went wrong (e.g., “Changes to how lighting is
239cb93a386Sopenharmony_ci      scaled in Skia r#### changed the following images:”)
240cb93a386Sopenharmony_ci    - Layout tests affected
241cb93a386Sopenharmony_ci    - You should copy the list of affected from stdio of the failing bot
242cb93a386Sopenharmony_ci  - Status: Assigned
243cb93a386Sopenharmony_ci  - Owner: yourself
244cb93a386Sopenharmony_ci  - cc: bsalomon@, robertphillips@ & developer responsible for changes
245cb93a386Sopenharmony_ci  - Labels: OS-All & Cr-Blink-LayoutTests
246cb93a386Sopenharmony_ci  - If it is filter related, cc senorblanco@
247cb93a386Sopenharmony_ci
248cb93a386Sopenharmony_ci- (Dispreferred but faster) Edit
249cb93a386Sopenharmony_ci  [skia/skia_test_expectations.txt](https://chromium.googlesource.com/chromium/+/refs/heads/trunk/skia/skia_test_expectations.txt)
250cb93a386Sopenharmony_ci
251cb93a386Sopenharmony_ci  - Add # comment about what has changed (I usually paraphrase the crbug text)
252cb93a386Sopenharmony_ci  - Add line(s) like the following after the comment:
253cb93a386Sopenharmony_ci    - crbug.com/<bug#youjustcreated> foo/bar/test-name.html [ ImageOnlyFailure ]
254cb93a386Sopenharmony_ci  - Note: this change is usually done in the DEPS roll patch itself
255cb93a386Sopenharmony_ci
256cb93a386Sopenharmony_ci- (Preferred but slower) Make a separate Blink patch by editing
257cb93a386Sopenharmony_ci  LayoutTests/TestExpectations
258cb93a386Sopenharmony_ci
259cb93a386Sopenharmony_ci  - Add # comment about what has changed (I usually paraphrase the crbug text)
260cb93a386Sopenharmony_ci  - Add line(s) like the following after the comment:
261cb93a386Sopenharmony_ci    - crbug.com/<bug#youjustcreated> foo/bar/test-name.html [ Skip ] # needs
262cb93a386Sopenharmony_ci      rebaseline
263cb93a386Sopenharmony_ci  - Commit the patch you created and wait until it lands and rolls into Chrome
264cb93a386Sopenharmony_ci
265cb93a386Sopenharmony_ci- Retry the DEPS roll (for the 1st/dispreferred option this usually means just
266cb93a386Sopenharmony_ci  retrying the layout bots)
267cb93a386Sopenharmony_ci- Make a Blink patch by editing LayoutTests/TestExpectations
268cb93a386Sopenharmony_ci
269cb93a386Sopenharmony_ci  - Add # comment about what has changed
270cb93a386Sopenharmony_ci  - Add line(s) like the following after the comment:
271cb93a386Sopenharmony_ci    - crbug.com/<bug#youjustcreated> foo/bar/test-name.html [ Skip ] # needs
272cb93a386Sopenharmony_ci      rebaseline
273cb93a386Sopenharmony_ci      - (if you took the second option above you can just edit the existing
274cb93a386Sopenharmony_ci        line(s))
275cb93a386Sopenharmony_ci
276cb93a386Sopenharmony_ci- If you took the first/dispreferred option above:
277cb93a386Sopenharmony_ci  - Wait for the Blink patch to roll into Chrome
278cb93a386Sopenharmony_ci  - Create a Chrome patch that removes your suppressions from
279cb93a386Sopenharmony_ci    skia/skia_test_expectations.txt
280