docs(l2): fix version number in upgrade docs#6515
Conversation
The CommonBridge l2GasLimit migration was introduced in v10, not v11. Also fixes the cross-reference anchor in the vanilla deployment docs.
c2df3d3 to
8f26914
Compare
The OnChainProposer is owned by the Timelock, so upgradeToAndCall and other onlyOwner operations (pause, unpause) cannot be called directly. They must go through the Timelock's emergencyExecute. This was not documented and causes confusing reverts for operators following the upgrade instructions. Also updates the implementation verification command to use cast instead of a raw JSON-RPC curl.
8f26914 to
82f4677
Compare
🤖 Kimi Code ReviewThis is a documentation-only PR with valid fixes. Here's the review: docs/l2/deployment/upgrades.md (lines 86, 89):
docs/l2/deployment/vanilla.md (line 93):
docs/l2/fundamentals/contracts.md (lines 132-135, 139):
Summary: Clean documentation improvements. No code changes, no security concerns. The Timelock note is particularly valuable for preventing operational errors. Automated review by Kimi (Moonshot AI) · kimi-k2.5 · custom prompt |
🤖 Claude Code ReviewHere is my review of PR #6515: PR #6515 —
|
Greptile SummaryThis PR fixes three documentation inaccuracies in the L2 docs: corrects version labels for the CommonBridge Confidence Score: 5/5Safe to merge — all changes are documentation corrections with no code impact. All three changes are purely documentation fixes that correct factual errors and add missing operational guidance. The timelock.md link target exists, the renamed anchor is consistent across files, and no code is affected. No files require special attention.
|
| Filename | Overview |
|---|---|
| docs/l2/deployment/upgrades.md | Version labels corrected from "v10→v11" to "v9→v10"; "From v11 onwards" phrase updated to "From v10 onwards" — aligns documentation with the actual release in which the CommonBridge l2GasLimit feature shipped. |
| docs/l2/deployment/vanilla.md | Cross-reference anchor updated from #from-v10-to-v11 to #from-v9-to-v10 to match the renamed section in upgrades.md — keeps the in-doc link functional. |
| docs/l2/fundamentals/contracts.md | Added Timelock ownership note for OCP upgrade path; also fixed curl command (hardcoded localhost → <L1_RPC_URL>, missing JSON string quotes around <PROXY_ADDRESS> added). |
Sequence Diagram
sequenceDiagram
participant Operator
participant Timelock
participant OCP as OnChainProposer (proxy)
participant Impl as New Implementation
Note over Operator,Impl: Upgrading OnChainProposer (OCP)
Operator->>Operator: Deploy new implementation contract
Operator->>Timelock: schedule(upgradeToAndCall, delay) OR emergencyExecute(upgradeToAndCall)
Timelock->>OCP: upgradeToAndCall(newImpl, initData)
OCP->>Impl: delegatecall initialize()
OCP-->>Operator: Upgrade complete
Note over Operator,OCP: Verify upgrade
Operator->>OCP: eth_getStorageAt(ERC1967 slot)
OCP-->>Operator: Returns new implementation address
Reviews (1): Last reviewed commit: "Add note about OCP ownership by Timelock..." | Re-trigger Greptile
🤖 Codex Code Review
Assumptions:
Aside from those doc regressions, this PR looks fine. No code-correctness, gas-accounting, consensus, or memory-safety concerns are in scope here because the patch is documentation-only. Automated review by OpenAI Codex · gpt-5.4 · custom prompt |
There was a problem hiding this comment.
Pull request overview
Fixes L2 documentation versioning and upgrade guidance so operators follow the correct upgrade path and don’t hit avoidable onlyOwner reverts when interacting with the OnChainProposer.
Changes:
- Correct the CommonBridge
l2GasLimitmigration section to be v9 → v10 (and “From v10 onwards”). - Update the vanilla deployment doc cross-reference to the corrected upgrades anchor.
- Add a Timelock ownership note clarifying OCP upgrades/admin actions must be executed via the Timelock.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| docs/l2/fundamentals/contracts.md | Adds Timelock ownership note for OCP and adjusts the RPC example placeholder. |
| docs/l2/deployment/vanilla.md | Fixes upgrades section anchor link to point at v9 → v10. |
| docs/l2/deployment/upgrades.md | Renames the upgrade section to v9 → v10 and updates the “from vX onwards” wording accordingly. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| rex send <PROXY_ADDRESS> 'upgradeToAndCall(address,bytes)' <NEW_IMPLEMENTATION_ADDRESS> <INITIALIZATION_CALLDATA> --private-key <PRIVATE_KEY> | ||
| ``` | ||
|
|
||
| > **Note:** The `OnChainProposer` is owned by the Timelock contract. You cannot call `upgradeToAndCall` on the OCP directly — it will revert with `onlyOwner`. The call must be routed through the Timelock. See [Timelock](./timelock.md) for the available paths (schedule + execute with delay, or `emergencyExecute` for immediate execution by the Security Council). | ||
| > |
There was a problem hiding this comment.
This note contradicts the immediately preceding step that instructs calling upgradeToAndCall directly on <PROXY_ADDRESS>. Consider rewording/restructuring so it’s clear that direct upgradeToAndCall works only when the proxy owner is your EOA, but for OnChainProposer upgrades/admin actions you must execute the call via the Timelock (and point readers to the Timelock doc for how to encode/route the call).
|
|
||
| ```sh | ||
| curl http://localhost:8545 -d '{"jsonrpc": "2.0", "id": "1", "method": "eth_getStorageAt", "params": [<PROXY_ADDRESS>, "0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc", "latest"]}' | ||
| curl <L1_RPC_URL> -d '{"jsonrpc": "2.0", "id": "1", "method": "eth_getStorageAt", "params": ["<PROXY_ADDRESS>", "0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc", "latest"]}' |
There was a problem hiding this comment.
<L1_RPC_URL> is introduced here but isn’t defined anywhere else in this document, and this “upgrade the contracts” section isn’t clearly L1-specific. To avoid confusion, use a generic placeholder like <RPC_URL> (or explicitly <L1_RPC_URL> vs <L2_RPC_URL> with a short explanation) and keep it consistent with the rest of the steps/tools.
| curl <L1_RPC_URL> -d '{"jsonrpc": "2.0", "id": "1", "method": "eth_getStorageAt", "params": ["<PROXY_ADDRESS>", "0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc", "latest"]}' | |
| curl <RPC_URL> -d '{"jsonrpc": "2.0", "id": "1", "method": "eth_getStorageAt", "params": ["<PROXY_ADDRESS>", "0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc", "latest"]}' |
Motivation
Two issues discovered while writing up a v9 → v10 upgrade runbook:
l2GasLimitmigration was labeled "From v10 to v11" but was actually introduced in v10 (i.e., the migration is from v9 to v10).docs/l2/fundamentals/contracts.mdshowsupgradeToAndCallbeing called directly on a contract proxy, but theOnChainProposeris owned by the Timelock — so any operator following those steps on the OCP hits anonlyOwnerrevert with no hint as to why.Description
docs/l2/deployment/upgrades.mddocs/l2/deployment/vanilla.md#from-v10-to-v11→#from-v9-to-v10)docs/l2/fundamentals/contracts.mdupgradeToAndCall(and otheronlyOwneroperations likepause/unpause) cannot be called directly — the call must be routed through the Timelock. Points to the Timelock doc for the available execution paths (scheduled with delay vs.emergencyExecute), without prescribing one.