mach: Allow updating test result metadata from GitHub Action run#41257
Merged
mrobinson merged 1 commit intoservo:mainfrom Dec 15, 2025
Merged
Conversation
This change allows `./mach update-wpt` to accept a URL to a GitHub Action run. If a URL is passed, it will attempt to download the stable unexpected results from the run and update the expected test results. Note that this currently requires having the `gh` command-line tool installed and authenticated. Although you can download artifacts without logging in via the web interface, doing this via the API requires an access token. Signed-off-by: Martin Robinson <[email protected]>
yezhizhen
approved these changes
Dec 14, 2025
| != 0 | ||
| ): | ||
| print(f"Could not download artifact from run id {run_id}.") | ||
| print("Is `gh` installed and authenticated?") |
Member
There was a problem hiding this comment.
The ` around gh here probably won't work as we want? Maybe something else to do the format.
Member
Author
There was a problem hiding this comment.
Oh yeah, this doesn't do anything special. I just put these here to make it clear that it is a command-line tool, but I can remove it.
Member
Author
There was a problem hiding this comment.
If it's okay with you, I'll land this as is. I think the quotes here do help with reading this a bit more easily, even though they don't change the formatting of the string.
Member
There was a problem hiding this comment.
It is a super nit anyway. What I had in mind is something like
\033[32mgh\033[0m
This was referenced Jan 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change allows
./mach update-wptto accept a URL to a GitHubAction run. If a URL is passed, it will attempt to download the stable
unexpected results from the run and update the expected test results.
Note that this currently requires having the
ghcommand-line toolinstalled and authenticated. Although you can download artifacts without
logging in via the web interface, doing this via the API requires an
access token.
Testing: This change adds a unit test for the regex that matches GitHub Action URLs.