Add local emergency redeployment rehearsal#143
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
✅ Files skipped from review due to trivial changes (1)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughAdds a local Foundry-based emergency redeployment rehearsal script and test that deploy two distinct stacks, verify Safe-rooted admin ceremonies and manifest/address distinctness, perform a replacement-only smoke mint, integrate the rehearsal into CI/local checks and Makefile, and update documentation, roadmap, ops state, and release checksums. ChangesLocal Emergency Redeployment Rehearsal Implementation
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.
Tip: disable this comment in your organization's Code Review settings.
|
@coderabbitai review |
✅ Action performedReview finished.
|
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@script/RehearseEmergencyRedeployment.s.sol`:
- Around line 95-109: The rehearsal currently computes oldDeploymentVersionHash
and replacementDeploymentVersionHash but never asserts they differ, so add a
failing assertion in run() to reject a replacement that reuses the historical
deploymentVersion: after computing replacementDeploymentVersionHash (and before
or after deploying replacementDeployment) compare oldDeploymentVersionHash !=
replacementDeploymentVersionHash and revert/fail the script if equal; reference
the variables oldDeploymentVersionHash, replacementDeploymentVersionHash and the
run() flow (you can reuse the existing assertion pattern used by
_assertDeploymentCeremony/_assertDistinctDeployments to surface the failure).
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 2ce0215d-b424-4559-bc43-b2a1ca4de17e
📒 Files selected for processing (18)
.github/workflows/ci.ymlCHANGELOG.mdMakefiledocs/deployment.mddocs/known-blockers.mddocs/status.mddocs/tooling.mdops/AUTONOMOUS_RUN.mdops/ROADMAP.mdrelease-artifacts/latest/SHA256SUMSrelease-artifacts/latest/release-checksums.jsonrelease-artifacts/latest/release-manifest.jsonscript/README.mdscript/RehearseEmergencyRedeployment.s.solscripts/check.ps1scripts/check.shtest/README.mdtest/StreamDeploymentManifest.t.sol
Summary
Closes #142.
Adds a local Anvil emergency redeployment rehearsal for the ADR 0007 / Gate E deployment evidence path. The rehearsal deploys an impacted old stack and a replacement stack with distinct deployment versions, manifest hashes, EIP-712 drop domains, and contract addresses; proves both ceremonies transfer control to the Safe placeholder and remove temporary deployer admin; and smoke-mints on the replacement stack through the signed fixed-price drop path.
This is intentionally local-only evidence. Fork/testnet/live emergency redeployment evidence remains a later Gate E blocker that should use real deployment inputs and retained broadcast artifacts.
Changes
script/RehearseEmergencyRedeployment.s.solfor the local two-stack redeployment rehearsal.test/StreamDeploymentManifest.t.solwith machine-checkable redeployment evidence assertions.make deploy-rehearsal, Linux/Windows local gates, and CI deployment-rehearsal logs.Validation
forge fmt script\RehearseEmergencyRedeployment.s.sol test\StreamDeploymentManifest.t.solforge test --match-path test\StreamDeploymentManifest.t.sol -vvvforge script script\RehearseEmergencyRedeployment.s.sol:RehearseEmergencyRedeployment --sig "run()" --via-irpython scripts\generate_release_manifest.pypython scripts\generate_release_checksums.pypython scripts\generate_release_manifest.py --checkpython scripts\generate_release_checksums.py --checkpython scripts\test_changelog_check.pypython scripts\check_changelog.pypython scripts\test_release_manifest.pypython scripts\test_release_checksums.pybash -n scripts/check.sh scripts/bootstrap-ec2.shmake checkscripts\check.ps1andscripts\bootstrap-windows.ps1powershell -NoProfile -ExecutionPolicy Bypass -File scripts\check.ps1git diff --checkSummary by CodeRabbit
New Features
Documentation
CI / Releases
Tests