chore: upgrade solana runtime to 4.2.2 - #127
Conversation
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (19)
💤 Files with no reviewable changes (2)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe change aligns workspace and crate dependencies with Agave 4.2.2. It ports shared CPI signer translation, raw memory-slice handling, invocation ordering, execution-cost changes, and SlotHashes decoding. SVM account loading now propagates instruction-sysvar encoding errors. Transaction account state tracks metadata for feature-gated rent transitions. Documentation records compatibility boundaries and omitted upstream functionality. Priority: ➖ Normal Change: Other Merge Risk: ⚪ Minimal · up to The runtime alignment changes retain the documented compatibility and execution contracts, with no unresolved merge-blocking behavior identified. 🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
Full details: Linked Issues checkExplanation For Full details: Docstring CoverageExplanation Docstring coverage is 47.83% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 23 functions across 7 files. (10 skipped: 10 unsupported.) ✨ Finishing Touches 💡 1📝 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 |
What changed
Upgrade the Agave runtime family to 4.2.2, retaining release-compatible SDK versions and the local account 4.3.1 fork. Port memory/CPI safety fixes, invocation-stack ordering, feature-gated SIMD-0392 rent checks, fallible instruction-sysvar construction, and SlotHashes decoding.
Closes #126
Impact
Borrowed-account storage, direct VM mapping, ephemeral restrictions, and private transaction framing remain unchanged. SIMD-0392 support does not activate the feature in Engine. Instruction-sysvar encoding failures now reject loading instead of supplying empty data.
Upstream compatibility requires removing the signer method from
SyscallInvokeSignedand the two modular-exponentiation cost fields. Mutable CPI slice translation becomes unsafe, and its underlying macro returns a raw pointer. The old C/Rust signer function names remain aliases of one implementation.Reviewer notes
Focus on aliasing and error paths in memory/CPI translation, synchronization of Engine’s additional syscall-context stack, and preservation of ephemeral exemptions in pre/post rent-state checks.
Intentionally omit upstream configurable sanitization, validator touched-flag/writeback plumbing, unused ABI-v2 scratchpads, and validator cache/deployment machinery. Keep Engine’s resize-owner check and error ordering. The account 4.3.0 → 4.3.1 upstream delta is frozen-ABI metadata that this fork does not consume. See the port disposition for upstream references and rationale. MBV integration remains in magicblock-labs/magicblock-validator#1660.