docs: replace dangling Extrospection reference with the codehash mechanism - #116
Conversation
…anism The Approach list pointed at the Rain Extrospection lib as the example mechanism for post-deploy bytecode integrity, but nothing in the tree uses it: that README line was the only mention anywhere, and the dependency set is forge-std and rain-sol-codegen only, so the lib is not available to be used. The bullet described an integration that does not exist. Replaced with what the source does — codehash comparison — naming RainDeployVerifyChain, LibAddressRegistry and LibMigrationRegistry so a reader can go read them. Says "access" rather than the issue's proposed "read" because LibMigrationRegistry gates applyMigration as well as applied and head, as its own comment spells out; "read" would have been a new, narrower inaccuracy. Closes #65 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Warning Review limit reached
Next review available in: 15 minutes 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?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. 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 |
|
Reviewed f1a6f83: ready — Closes #65. README only. The old bullet pointed at the Rain Extrospection lib, which this repo does not use; the replacement names the mechanism it actually has — CI green, 0 unresolved threads — vacuous, CodeRabbit reports |
Closes #65
The Approach list pointed readers at the Rain Extrospection lib as the example
mechanism for post-deploy bytecode integrity. Nothing in this repo uses it:
grep -rni extrospectionover the tree hit only that one README line, andremappings.txt/soldeer.lockcarry exactly two dependencies(
forge-std,rain-sol-codegen), so the lib is not even available to be used.The bullet described an integration that does not exist.
Replaced with what the source actually does —
codehashcomparison — namingthe contracts a reader can go read.
Deviation from the issue's proposed text
The issue proposed
...and before every registry **read** by LibAddressRegistry and LibMigrationRegistry. That is accurate forLibAddressRegistry, whose onlyfunction is the read
resolve, but narrower thanLibMigrationRegistry, whichgates the write
applyMigration(line 168) as well as the readsapplied(122) and
head(139). The library's own comment is explicit that this is thepoint: "Both entry points check ... a read would branch a test on whatever that
code returned, and a write would record a migration somewhere nothing will ever
read it."
Shipping "read" verbatim would have swapped a stale-example inaccuracy for a
too-narrow one, so the wording is
access, the property both libraries share.The issue's own verification block used the same wider phrasing ("gate every
registry touch on a codehash pin"); only the proposed-fix line narrowed it.
Verification
Every call site named in the new text was read at this branch's base
(
86f8d96) and does what the text says:src/abstract/RainDeployVerifyChain.sol:88-100—checkDeployedOnNetworkreverts
NotDeployedOnNetworkon empty code, then comparesderived.deployedAddress.codehashagainstderived.bytecodeHash.src/lib/LibAddressRegistry.sol:45-52—resolvecompares the registry'scodehashagainstADDRESS_REGISTRY_DEPLOYED_CODEHASHbefore thegetcall.src/lib/LibMigrationRegistry.sol:93-100—checkCodeHashcompares againstMIGRATION_REGISTRY_DEPLOYED_CODEHASH; called from all three entry points.Post-change
grep -rni extrospectionover the tree (excluding.git,dependencies,out) returns nothing.Documentation only — no Solidity changed.
QA
pin wording rather than behaviour. The discriminating check is
git grep -ni extrospection <rev> -- README.md src script test foundry.toml remappings.txt soldeer.lock, which fails on base (86f8d96:README.md:36) andreturns no hits at this head.
gates run:
reuse lintexit 0 (71/71 files compliant); pre-commit(denofmt, no-consumer-prettier) passed on the commit.
the new text names was opened and confirmed to compare
codehash:RainDeployVerifyChain.checkDeployedOnNetwork(src/abstract/RainDeployVerifyChain.sol:88-100),
LibAddressRegistry.resolve(src/lib/LibAddressRegistry.sol:45-52), and
LibMigrationRegistry.checkCodeHash(src/lib/LibMigrationRegistry.sol:93-100), whose three callers were enumerated
by grep to establish that "access" and not "read" is the correct word.
reference and describe the real mechanism. Covered. The grep that found the
finding was re-run tree-wide post-change and is clean, so the category
(dangling references to this absent lib) is exhausted, not just the cited line.