Closed Bug 1523690 Opened 5 years ago Closed 2 years ago

Make a bot auto-submit webrender try pushes for patches that touch gfx/wr

Categories

(Core :: Graphics: WebRender, defect, P3)

Other Branch
defect

Tracking

()

RESOLVED WONTFIX

People

(Reporter: kats, Unassigned)

References

Details

This is sort of a regression from the old github workflow, where each PR would automatically trigger the webrender CI jobs, without additional effort on the patch author's part. With the m-c/phabricator workflow authors have to explicitly do try pushes including the wrench jobs in order to get the same pre-landing test coverage.

Given the number of WR patches that have been backed out over wrench failures it's probably worth standing up a bot to provide this service - it would listen for phabricator patches that touch any file in gfx/wr and do a try push, and then report the try push URL back as a comment on phabricator. It could even wait until the jobs are done and then try and report success/failure.

Oh, and Sylvestre pointed me to https://github.com/mozilla/release-services/ which is where other phabricator-commenting bots live. We could probably put our bot in there too.

Priority: -- → P3

Bastien, is the infrastructure you described in your dev-platform post something that can be used to fix this bug? The quick version is that we have an existing taskcluster jobs (e.g. here) that run to lint/test any changes in the gfx/wr/ subtree of mozilla-central. Right now those job run after landing but we'd like to also run them similar to the reviewbot/lint checks when a patch is uploaded to Phabricator. Maybe just starting with the lint one since that's relatively cheap?

Flags: needinfo?(bastien)

That totally looks like something we could do !

You would need to add the code-review attribute on your CI task definition, so that it's automatically triggered by our bot workflow.
The task would then need to run using the environment variables provided by the taskgraph and do the following:

  1. Clone mozilla-central and checkout your target revision (i assume you already do that)
  2. Run any analyzer on your source code
  3. Produce a JSON artifact listing all your issues

The bot will download your JSON artifact, parse it, build issues in a common format, filter them, then publish the relevant ones on Phabricator.
Depending on your JSON output, you may need to add a parser on our side (in https://github.com/mozilla/release-services/) : i can assist you here of course.
If you match the mozlint output, development will be minimal (like 3 lines of config).

Flags: needinfo?(bastien)

FYI, this is pretty easy to do. Here is what I did to add the Rustfmt check!
https://phabricator.services.mozilla.com/D32570

(In reply to Bastien Abadie [:bastien] from comment #3)

You would need to add the code-review attribute on your CI task definition, so that it's automatically triggered by our bot workflow.
The task would then need to run using the environment variables provided by the taskgraph and do the following:

  1. Clone mozilla-central and checkout your target revision (i assume you already do that)
  2. Run any analyzer on your source code
  3. Produce a JSON artifact listing all your issues

Thanks! This sounds pretty easy. The hardest part is going to be formatting the output in a more parseable way. Right now it's just whatever the servo-tidy tool spews out but we should clean it up some.

I don't think we plan to do this.

Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.