feat(api): surface node mode identity on the overview page - #11
Conversation
…l mining flag Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Ready to act? Review this PR in Change Stack to turn feedback into patch suggestions you can inspect and refine. 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 (5)
📝 WalkthroughWalkthroughThe PR adds mining enablement tracking to the node identity model by introducing a ChangesNode identity mining enablement and overview UI display
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 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 docstrings
🧪 Generate unit tests (beta)
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 |
…index (#23) read_ergo_box parses the 32-byte transaction id and the VLQ output index from the box tail, but the SBox-constant EvalBox in sigma_to_value hardcoded transaction_id: [0u8;32] and output_index: 0, discarding them. This corrupted ExtractCreationInfo (0xC7) — whose R3 reference is transactionId.toBytes ++ Shorts.toByteArray(index) (FIXED 2-byte big-endian) — and ExtractBytesWithNoRef (0xC4), whose strip length is 32 + VLQ(index) (so a zeroed index strips the wrong number of bytes for index >= 128). Now carries the parsed ergo_box.transaction_id / ergo_box.index. Matches Scala ErgoBox.get(ReferenceRegId) and bytesWithNoRef. Closes sbox-const-discards-txid-index (3 entries: Box_properties_equivalence 0xC7 #10/#11 and 0xC4 #8). Co-authored-by: arkadianet <rkadias@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
What
The dashboard never rendered
/api/v1/identitydespite the endpoint being registered in the web client and theApiIdentity.modedoc comment stating it was designed for the dashboard hero strip. The overview's top row now shows the mode label ("archive · utxo", "digest-verifier", "pruned · utxo · keep N", …) with compact pills for mining / extra-index / verify-tx and bootstrap provenance (shown only when a jump actually ran). Fetched once on mount (static config), hidden on fetch failure — the page never breaks.Plus one real bug
build_api_identity_from_inputshardcodedmining: false— a live mining node reportedmining:falseon/api/v1/identity(same class as the/info isMiningstub fixed in #7).IdentityInputsnow carriesmining_enabledfrom config; all constructors swept; unit test pins the flow both ways.Verification
fmt/check/clippy(CI-exact) clean;
cargo test -p ergo-node --lib346 green;cargo test -p ergo-apigreen. UI matches the existing cockpit visual language (existing.pillcomponents, token-based CSS, no new design primitives); assets are compile-time embedded so this rides the next binary deploy.🤖 Generated with Claude Code
Summary by CodeRabbit
New Features
Bug Fixes
Style