Repository navigation
Canary test to catch perf regressions - #7507
Conversation
|
Thanks @mattnibs. I've pushed a commit that should address your feedback.
I just added that. For instance now you can do
Correct. On macOS for instance, they land in
I've made those changes. FWIW, the I also pushed a change that may mark some results as "noisy", which catches situations like what I just bumped into when testing locally on my laptop. I happened to launch my email client in the middle of a run, which made my laptop start running slower, and it basically created a mix of good results and garbage results that made the deltas hard for the scripts to compare, i.e., they looked to me like there might be a regression, but the scripts were not previously flagging it as "red", and it was because it already had logic to ignore that situation but wasn't showing its work. These still aren't flagged as regressions, but they're now marked "noisy" in the results with a tip to re-run. Hopefully these won't come up on calm laptops or Actions runs. Re-checking the ~20 earlier runs from my testing, most of them in Actions, only my laptop run got marked. But Actions runners are VMs, so I guess we can't rule out "noisy neighbor"/infra effects there too. All of the above are also covered in the |
This provides a way to easily run the GitHub Archive Sample queries to help us spot perf regressions early. The
perf/canary/README.mdhas all the details, but in brief:make perfto compare your local work with themaincommit your branch started frommainwith the currentmain, in parallel with the existing CImainThese all produce Markdown reports that highlight significant changes in time or memory usage, as well as any change in query results.
It never fails a build and isn't a required check. On PRs it takes about the same time as the existing tests, and it skips changes that only touch
book/or Markdown files.Examples
I've got examples in a personal fork that show how this would have surfaced some of our recent regressions:
There's also an open PR philrz#2 that shows how it would look during the PR workflow. Notice the "neutral check" with the link to the report. We could turn this up to a fully "red" failure so it's harder to ignore, but I figured we'd start this out gently until we have confidence that it's not surfacing false positives.
Code
Disclosure: Claude wrote the Go code. I've tested it locally and on my fork (examples above).