Conversation
This was referenced Jun 23, 2026
Collaborator
Author
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
This was referenced Jun 23, 2026
73c6092 to
3c15947
Compare
076b715 to
b45cdf8
Compare
367c7dc to
5f260c4
Compare
114bf56 to
4e0fa26
Compare
e26900b to
7921abb
Compare
756dc43 to
63b2969
Compare
11b31fc to
ffefa44
Compare
6584d35 to
3cab4ae
Compare
4017081 to
e4a411b
Compare
9bb4f46 to
9efac37
Compare
b3c95bd to
fe72258
Compare
0bf5e1b to
c81a74f
Compare
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.

What changed
Added the engine's built-in MagicRoot program as two crates:
magic-root-program(execution) and
magic-root-interface(shared instruction schema).Why
The engine needs a privileged built-in for account changes no ordinary program
may make — patching arbitrary fields, finalizing, and closing accounts — while
letting callers build those instructions without depending on execution logic.
Part of #4.
Impact
magic-root-programis wired in asMagicRootEntrypoint; the schema lives innucleus::runtime.Finalizedebits lamports from the payer to conserve supply and loadsexecutable targets into the tx program cache;
DeletesetsAccountMode::Closed;PostFinalizeCPIs follow-ups after rejecting immutable writable accounts.magic-root-interfaceexposesMagicRootInstructionandcomposesoenginecan build instructions without the program crate.
Reviewer notes
The program is unrestricted, so it is authority-gated: every instruction must be
top-level (no CPI) and signed by
AUTHORITY, checked before any account is touched.Follow-up
engineissues account CRUD as MagicRoot instruction sequences upstack.