Repository navigation
tests/test_release_workflow.py runs the wheel check's whole step on a rehearsal's branch and on the version's tag, so a TAG taken from the ref's name, or a REPOSITORY hard-coded to the code leg, fails the suite (closes opensoft/openRepoTools#285) - #8
Merged
Merged
Conversation
… rehearsal's branch and on the version's tag, so its bash line cannot take TAG from the ref's name and pass the suite (#285)
The wheel check's bash line exports TAG, COMMIT and REPOSITORY, and the line after it names the wheel at $RUNNER_TEMP/dist-a/openrepotools-$VERSION-py3-none-any.whl. No test ran either: the heredoc was run alone, with its values handed in through the environment. So lane openRepoTools-2's mutant WX1, TAG="$GITHUB_REF_NAME", survived the suite (-k test_release_workflow, 499 passed). It can only fail a rehearsal on a branch, since the ref step already refuses any ref but refs/tags/v$VERSION.
The new test puts the wheel as built for the release at that path and runs the step as GitHub runs it, with only the values GitHub sets: VERSION, GITHUB_SHA, GITHUB_REPOSITORY, GITHUB_REF, GITHUB_REF_NAME and the step's own DIGEST, and `python3` this interpreter. It runs on refs/heads/l3-rehearsal-v1.1.0 with 1.1.0rc1 and on refs/tags/v1.1.0 with 1.1.0, and each must pass the stamp check and run to its last line. Under WX1 the branch case fails with the heredoc's "the release's values {... 'TAG': 'l3-rehearsal-v1.1.0' ...} are not this run's {... 'TAG': 'v1.1.0rc1' ...}"; the tag case passes either way, as the ref's name is the tag there.
Only tests/test_release_workflow.py changes, and release.yml is as it was. -k test_release_workflow: 501 passed.
A branch for the code leg, not a pull request: it is cherry-picked into openRepoTools-code after v1.1.0 is tagged.
Part of #285.
Lane: openRepoTools-2
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
(cherry picked from commit 9f161a99205337421acd243eb591f95bc11acd25)
…h case in opensoft/openRepoTools, with its wheel stamped to match, so a REPOSITORY hard-coded to the code leg in the step's bash line fails the suite (#285) Lane openRepoTools-2's review of #285's commit (RV-A) found one SHOULD. Both of the test's cases took REPOSITORY and GITHUB_REPOSITORY from `wheel_release()`, which gives the code leg's name (opensoft/openRepoTools-code), so a bash line that exports `REPOSITORY="opensoft/openRepoTools-code"` (release.yml:809) instead of `REPOSITORY="$GITHUB_REPOSITORY"` passed both. In production that line would refuse every run outside the code leg, and the only release runs so far (39416933776 on main, a branch rehearsal, and 39417405752 on v1.1.0rc1) ran in opensoft/openRepoTools. The rehearsal-branch case now runs in `THIS_REPOSITORY`, opensoft/openRepoTools, as rehearsals run today, with the wheel stamped with that name. `WHEEL_CHECK_REFS` holds the run's repository beside the ref and the version, and the test builds its release values from `wheel_release()` with that repository. The tag case is as it was, in the code leg, so a REPOSITORY hard-coded to either name fails one of the two cases. Only tests/test_release_workflow.py changes: release.yml is as it was, no test is added or removed, and the two cases keep their ids. A branch for the code leg, not a pull request: it is cherry-picked into openRepoTools-code after v1.1.0 is tagged, on top of 9f161a9. Part of #285. Lane: openRepoTools-2 Co-Authored-By: Claude Sonnet 5.5 <[email protected]> (cherry picked from commit 33abe8ad2aae5d566c52932913b7de003d9f8c09)
Reviewer's GuideTestsExtend the release-workflow test inventory and add whole-step wheel-check coverage for rehearsal-branch and version-tag runs, checking that TAG and REPOSITORY match each run.
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Hey - I've reviewed your changes and they look great!
Linked issues
#285 release.yml's wheel check exports TAG, COMMIT and REPOSITORY in a bash line that no test runs, so a TAG taken from the ref name passes the suite · 3 of 3 met
| # | Requirement | Status | Notes |
|---|---|---|---|
| 1 | Run the wheel check's whole step with a synthetic wheel at the path the step expects. | ✅ Met | The test writes the wheel under RUNNER_TEMP/dist-a and runs the selected step through Runner, then checks that it reaches its final command. |
| 2 | Exercise a rehearsal branch and the version's tag, and ensure TAG is v$VERSION rather than the ref name. | ✅ Met | WHEEL_CHECK_REFS covers refs/heads/l3-rehearsal-v1.1.0 and refs/tags/v1.1.0; the rehearsal case makes a TAG derived from the ref name fail. |
| 3 | Check the run's repository value in the wheel stamp for both dispatch contexts. | ✅ Met | The rehearsal case uses THIS_REPOSITORY and the tag case uses CODE_LEG; each synthetic wheel is stamped with the corresponding repository. |
Sourcery assessment
Approved.
The in-place merge of runbook v9: the stack grows by this clean merge, with no force-push. Lane: openRepoTools-2 Co-Authored-By: Claude Opus 5.5 <[email protected]>
The in-place merge of runbook v9: the stack grows by this clean merge, with no force-push. Lane: openRepoTools-2 Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
This was referenced Nov 9, 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.



Lane: openRepoTools-2
Claim: opensoft/openRepoTools#285 (comment)
release.yml's wheel check exports TAG, COMMIT and REPOSITORY in a bash line that no test ran: the
check's heredoc was run alone, with its values handed in through the environment, so a TAG taken
from the ref's name passed the suite. The first pick runs the whole step as GitHub runs it, on a
rehearsal's branch and on the version's tag. The second runs the rehearsal-branch case in
opensoft/openRepoTools, with its wheel stamped to match, so a REPOSITORY hard-coded to the code leg
fails one of the two cases. Only tests/test_release_workflow.py changes, and release.yml is as it
was.
The picks, from lane openRepoTools-2's branches in opensoft/openRepoTools, each made with
git cherry-pick -xand followed by its source commit:(cherry picked from commit 9f161a99205337421acd243eb591f95bc11acd25)
(cherry picked from commit 33abe8ad2aae5d566c52932913b7de003d9f8c09)
Closes opensoft/openRepoTools#285.
Lane: openRepoTools-2
Co-Authored-By: Claude Sonnet 5.5 [email protected]
🤖 Generated with Claude Code
Summary by Sourcery
Expand release workflow tests to ensure the wheel check derives release metadata from the workflow environment across rehearsal and tagged runs.
Bug Fixes:
Enhancements:
Tests: