chore: sync sc-feat/opcm2-upgrade-op-chain with develop#763
Merged
0xiamflux merged 4 commits intosc-feat/opcm2-upgrade-op-chainfrom Dec 17, 2025
Merged
chore: sync sc-feat/opcm2-upgrade-op-chain with develop#7630xiamflux merged 4 commits intosc-feat/opcm2-upgrade-op-chainfrom
0xiamflux merged 4 commits intosc-feat/opcm2-upgrade-op-chainfrom
Conversation
…8583) * feat: have OPCMv2 check upgrade ordering version This PR introduces a check in OPCM that validates that the version difference in the previous OPCM and the current OPCM is acceptable. This PR explicitly disallows skipping OPCM versions which was previously an implicit requirement. * fix: properly set version testing flag * fix: semver lock * fix: move valid instructions allowance * fix: semver lock * fix: better mechanism for checking permitted upgrades * fix: properly run permitted upgrade sequence tests
* chore: bump opcmv2 to v7 * fix: correct version in upgrade sequence * fix: broken tests
0xOneTony
approved these changes
Dec 17, 2025
a425048
into
sc-feat/opcm2-upgrade-op-chain
1 of 2 checks passed
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.
Note
Adds upgrade sequence validation to OPContractsManagerV2, replaces constant version with a pure function and internal accessor, and introduces a semgrep rule to enforce using the internal version accessor.
versionfrom constant tofunction version() purereturning"7.0.0"; add_version()internal accessor and replace internal comparisons.isPermittedUpgradeSequence(ISystemConfig)with semver-based checks; enforce in_applyfor non-initial upgrades.OPContractsManagerV2_InvalidUpgradeSequence(string _lastVersion, string _thisVersion).IOPContractsManagerV2and ABI; refreshsemver-lockhashes.sol-safety-opcmv2-use-internal-versionto require_version()instead of directversion(); add corresponding test case.--error)._version()/version()behavior.Written by Cursor Bugbot for commit 5a087eb. This will update automatically on new commits. Configure here.