Conversation
WalkthroughThis PR adds a new network upgrade height entry (Xxx) across multiple network configurations and introduces a corresponding Height enum variant that maps to NetworkVersion::V28. The NEWEST_NETWORK_VERSION is updated from V25 to V27, and logging infrastructure for the upgrade event is added. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Comment |
GoldenWeek is still commented out in ForkUpgradeParams, so these files should not change. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
45935fa to
bd084c4
Compare
There was a problem hiding this comment.
♻️ Duplicate comments (1)
src/rpc/methods/state.rs (1)
3145-3146:⚠️ Potential issue | 🟠 MajorExpose these heights through
StateGetNetworkParams.Keeping
upgrade_golden_week_heightandupgrade_xxx_heightcommented here means the RPC still hides configured upgrade epochs even though the chain config now carries them. That leaves the nv28 skeleton only partially wired and still diverges from Lotus'ForkUpgradeParamssurface.Also applies to: 3194-3195
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/rpc/methods/state.rs` around lines 3145 - 3146, The RPC response for StateGetNetworkParams currently omits upgrade_golden_week_height and upgrade_xxx_height (they are commented out); update the StateGetNetworkParams-related types and serialization in src/rpc/methods/state.rs to include these fields (matching Lotus' ForkUpgradeParams surface), wire them into the code path that builds the network params from the chain config (pull values from the chain config / ForkUpgrade params used elsewhere), and ensure they are populated and returned by the StateGetNetworkParams handler (update any response struct, JSON keys, and tests if present) so the RPC exposes those configured upgrade epochs.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Duplicate comments:
In `@src/rpc/methods/state.rs`:
- Around line 3145-3146: The RPC response for StateGetNetworkParams currently
omits upgrade_golden_week_height and upgrade_xxx_height (they are commented
out); update the StateGetNetworkParams-related types and serialization in
src/rpc/methods/state.rs to include these fields (matching Lotus'
ForkUpgradeParams surface), wire them into the code path that builds the network
params from the chain config (pull values from the chain config / ForkUpgrade
params used elsewhere), and ensure they are populated and returned by the
StateGetNetworkParams handler (update any response struct, JSON keys, and tests
if present) so the RPC exposes those configured upgrade epochs.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 73c60730-d43d-4e56-a4d4-b708a895e489
📒 Files selected for processing (7)
src/networks/butterflynet/mod.rssrc/networks/calibnet/mod.rssrc/networks/devnet/mod.rssrc/networks/mainnet/mod.rssrc/networks/mod.rssrc/rpc/methods/state.rssrc/utils/misc/logo.rs
🚧 Files skipped from review as they are similar to previous changes (3)
- src/networks/butterflynet/mod.rs
- src/networks/devnet/mod.rs
- src/networks/calibnet/mod.rs
Codecov Report❌ Patch coverage is
Additional details and impacted files
... and 7 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
Summary of changes
Changes introduced in this pull request:
Reference issue to close (if applicable)
Closes #6704
Other information and links
Change checklist
Outside contributions
Summary by CodeRabbit
Release Notes
New Features
Tests