feat(ci): re-benchmark a release via workflow_dispatch tag input - #253
Merged
Conversation
Allows re-running benchmarks for an existing tag and overwriting its snapshot under bench-results/data/<tag>. Faithful refresh: each bench job checks out the tag's own harness + library (ref: inputs.tag), while the archival step runs from the current workflow so the FETCH_HEAD fix and snapshot keying apply to old tags too. - workflow_dispatch.inputs.tag (blank = main snapshot, unchanged behavior) - SNAPSHOT/COMMIT/REF resolve to the dispatched tag when present - meta.commit now records the benchmarked commit, not the default branch Dispatch from the default branch, e.g.: gh workflow run bench.yml -f tag=v0.6.0
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.
Summary
Adds a
workflow_dispatchtaginput to the Benchmarks workflow so an existing release can be re-benchmarked on demand and its snapshot overwritten underbench-results/data/<tag>.Faithful refresh (Option A): each bench job checks out the tag's own harness + library source (
ref: ${{ inputs.tag || github.ref }}), while the workflow definition — including the archival step — runs from the dispatched ref (the default branch). That means the recent FETCH_HEAD archival fix and snapshot keying apply even when refreshing old tags.Behavior
tagblank / normal tag-push: unchanged (main-<sha>or pushed-tag snapshot).tag=vX.Y.Z:SNAPSHOT/COMMIT/REFresolve to that tag; results land indata/<tag>.meta.commitnow records the benchmarked commit (via abench-rustjob output), not the default-branch sha.Usage
gh workflow run bench.yml -f tag=v0.6.0 # run from the default branchCaveats
checkout bench-resultspathspec bug), since archival runs from main.YAML validated locally (
yaml.safe_load).