Skip to content

fix(ci): rename the codegen script to script/Build.sol - #267

Open
thedavidmeister wants to merge 1 commit into
mainfrom
2026-08-21-codegen-script-build-sol
Open

fix(ci): rename the codegen script to script/Build.sol#267
thedavidmeister wants to merge 1 commit into
mainfrom
2026-08-21-codegen-script-build-sol

Conversation

@thedavidmeister

@thedavidmeisterthedavidmeister commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

What this fixes

The whole copy-artifacts job on main, which fails at its first real step:

::error::src/generated/ is committed but script/Build.sol was not found,
so the committed sources cannot be currency checked here.
The codegen script must be script/Build.sol.

rainix's rainix-copy-artifacts.yaml matches the codegen script name
exactly, on purpose: a repo that renames or drops it should go red rather
than skip regeneration and still report a green currency check. This repo's
script is script/BuildPointers.sol, so the job dies at the gate and the
currency check never runs at all.

This is not a regression in this repo — nothing here changed. The gate is new,
and copy-artifacts last passed on 2026-07-15 only because the gate did not
exist then.

What changed

script/BuildPointers.solscript/Build.sol, and the contract inside it
BuildPointersBuild. Plus the one stale reference in CLAUDE.md.

src/generated/LogTables.pointers.sol is not regenerated by this PR and
does not need to be. Its header

// THIS FILE IS AUTOGENERATED BY ./script/BuildPointers.sol

still names the old path because that string is hardcoded in
rain-sol-codegen-0.1.0's LibCodeGen.filePrefix() — it is not derived from
the script's filename. So regeneration after the rename is byte-identical.
Hand-editing that header to say Build.sol would be the thing that breaks the
currency check, not the thing that fixes it.

QA

  • Discriminating tests: n/a - no unit test covers a CI job's own gating step. The discriminating check is the copy-artifacts job itself, which fails on base at the "Regenerate generated sources" step with the error quoted above (observed on PR fix(test): drop vm.skip from the tagged deploy constants check #265, run 32508961076, job 96855392758) and is expected to get past it here. This PR's own copy-artifacts run is the verification.
  • Mutations applied: n/a - a file/contract rename with no behavioural logic to mutate. The one falsifiable claim (that regeneration is byte-identical after the rename, i.e. the autogen header is a hardcoded string rather than derived from the filename) was tested directly rather than by mutation: see Oracle.
  • Oracle: rainix's own workflow source, replayed locally against this exact commit rather than taken on trust. Ran the full rainix-copy-artifacts.yaml sequence at rainix SHA 3d1c85eca08ef5a852215f77c8f3684c8313a8b3 - name gate, forge script ./script/Build.sol, forge build, forge script ./script/CopyArtifacts.sol --ffi, forge fmt, git diff --exit-code. Result: gate PASS, codegen rc=0, and the currency check clean (DIFF-RC=0, no untracked files), which confirms the regenerated LogTables.pointers.sol is byte-identical to the committed one.
  • Category check: no issue - this is one of several independently diagnosed causes of red CI on main. Covers exactly one: the copy-artifacts name gate. It does not touch the deploy constants or the agent-context cap, which are separate causes with their own PRs.

Overlap with #256 and #268

⚠️#256 already contains this exact rename as one commit inside a larger PR.
This PR is the same fix isolated; the two will conflict.

This PR's one-line CLAUDE.md edit is in the ### Scripts section, which
#268 (the agent-context byte cap fix) deletes outright. If both land, take
#268's deletion.

Scope

A rename. No behaviour, no generated output, no test changed.

rainix's copy-artifacts job now requires the codegen script to be exactly
`script/Build.sol` when `src/generated/` is committed:
::error::src/generated/ is committed but script/Build.sol was not found,
so the committed sources cannot be currency checked here. The codegen
script must be script/Build.sol.
The gate exists so a repo that renames or drops its codegen script goes red
rather than silently skipping regeneration and reporting a green currency
check. This repo's script was `script/BuildPointers.sol`, so the whole job
fails at that step. It passed before only because the gate did not exist
yet.
Rename the file and the contract to match. The generated
src/generated/LogTables.pointers.sol is unchanged: its
"AUTOGENERATED BY ./script/BuildPointers.sol" header is a hardcoded string
in rain-sol-codegen-0.1.0's LibCodeGen.filePrefix(), not a function of the
script's filename, so regeneration is byte-identical and the currency check
stays clean.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@coderabbitai

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@thedavidmeister, you've reached your PR review limit, so we couldn't start this review.

Next review available in:40 minutes

Limit 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.

How can I continue?

Wait for the limit to reset, then comment @coderabbitai review or push new commits to the PR.

An organization admin can change what happens after included review limits in Billing.

How do review limits work?

CodeRabbit enforces per-developer PR review limits within each organization.

For paid Pro and Pro+ reviews, CodeRabbit uses a developer's included PR review attempts over the past 7 days to set the current hourly allowance. At typical activity levels, the full plan allowance applies. Higher sustained activity can lower the allowance until earlier attempts leave the 7-day window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 82ef2ee1-bed4-4cb7-97ed-d9597d9c13d6

📥 Commits

Reviewing files that changed from the base of the PR and between d3fb611 and 4173aff.

📒 Files selected for processing (2)
  • CLAUDE.md
  • script/Build.sol

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@thedavidmeister