Check generated files are current at PR time - #156
Merged
Conversation
src/generated/ is committed but nothing re-derived it until rainix-tag-release regenerated at tag time — after the deploy had already been broadcast. This is the PR-time twin that release-time regen assumes exists. Closes #152 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Warning Review limit reachedNext included review available in 42 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
src/generated/is committed here, but nothing re-derived it on a push. Thefirst thing that regenerated it was
rainix-tag-releaseat tag time — afterManual sol artifactshad already broadcast the deploy.rainix-tag-releaseassumes a PR-time twin of that regen exists; in this repo it did not.
Adds
.github/workflows/git-clean.yamlcallingrainlanguage/rainix/.github/workflows/rainix-copy-artifacts.yaml@main, whichre-runs
script/Build.sol,forge build,forge fmt, thengit diff --exit-code.Names follow the 2026-08-27 ruling on #152: file
git-clean.yaml, workflowname: Git is clean, job idgit-clean. Shape copied from rain.metadata.deployand rain.factory.deploy, which are identical to each other and differ from this
only in the pre-ruling job id.
Closes #152
QA
test, a CI-only diff has no unit test that could exercise it. Run
https://github.com/rainlanguage/rain.deploy/actions/runs/33043677967 on this
branch is green, and every step that does the checking actually executed
rather than being skipped:
Regenerate generated sourcesranforge script ./script/Build.sol("Compiling 56 files with Solc 0.8.25","Script ran successfully. Gas used: 3051805"),
Build Solidityranforge build("Compiling 49 files", "Solc 0.8.25 finished in 20.76s"),Formatranforge fmt, andAssert committed artifacts match freshly builtran
git diff --exit-codeclean. The three-steps (Regenerate meta artifacts,Copy forge artifacts into committed location,Regenerate derived artifacts) skip onhashFiles()ofscript/build-meta.sh,script/CopyArtifacts.solandscript/build.sh, none of which this repo has.Fails on base trivially: on
mainthe workflow does not exist, so there is norun at all.
src/generated/candidate/AddressRegistry.solline 8 →BYTECODE_HASHlast byte0x97→0xde→ killed by the new workflow onbranch
qa-git-clean-red-check, runhttps://github.com/rainlanguage/rain.deploy/actions/runs/33044029088, which
failed at
Assert committed artifacts match freshly builtprinting the exactone-line diff restoring
0x97. That provesBuild.solreally rewrote thefile and that
git diffreally read the result — a workflow that skippedregeneration would have gone green on the corrupted pin.
(
rainix-copy-artifacts.yaml), read to enumerate which steps areunconditional and which are
hashFiles()-gated, and the two conformingsiblings' caller files for the shape. Expected step list derived from the
reusable before the run, not read back off it.
rainix-copy-artifactscurrencycheck under the ruled
git-cleannames; covered. The issue also namesrain.extrospection.deploy as missing it — out of scope here, tracked at
Standardise the currency check on git-clean (file, workflow name and job id) rain.extrospection.deploy#7 per the ruling comment.
🤖 Generated with Claude Code