Skip to content

feat: add id for actions#1409

Open
taco-paco wants to merge 1 commit into
masterfrom
feat/action-ids
Open

feat: add id for actions#1409
taco-paco wants to merge 1 commit into
masterfrom
feat/action-ids

Conversation

@taco-paco

@taco-paco taco-paco commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Summary

Add a stable per-action id so actions can be addressed independently of their position in the bundle — positional indexing.
This is needed for coming patching of intents as we have to refer to actions somehow

Breaking Changes

  • None
  • Yes — migration path described below

@lucacillario During deploy we need to make sure that MagicContext is empty

Test Plan

Summary by CodeRabbit

  • Enhancements

    • Scheduled actions now use stable identifiers, improving action retrieval and callback association.
    • Action construction and scheduling support consistent identifier assignment across bundles.
  • Bug Fixes

    • Improved reliability when locating actions during scheduling and callback processing.
  • Tests

    • Updated unit and integration test fixtures to include action identifiers.

@coderabbitai

coderabbitai Bot commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 8850e285-7442-4109-9329-277a7cdb9b5c

📥 Commits

Reviewing files that changed from the base of the PR and between 4b70fd8 and c34d411.

📒 Files selected for processing (8)
  • magicblock-committor-service/src/tasks/mod.rs
  • magicblock-committor-service/src/tasks/task_strategist.rs
  • magicblock-core/Cargo.toml
  • programs/magicblock/src/magic_scheduled_base_intent.rs
  • programs/magicblock/src/schedule_transactions/process_add_action_callback.rs
  • programs/magicblock/src/schedule_transactions/process_schedule_intent_bundle.rs
  • test-integration/test-committor-service/tests/test_intent_executor.rs
  • test-integration/test-committor-service/tests/test_transaction_preparator.rs

📝 Walkthrough

Walkthrough

Base actions now receive sequential stable IDs from ConstructionContext. Intent construction passes mutable context through scheduled, commit, and undelegation builders, while standalone actions are collected explicitly. Mutable action lookup across intent and action types now matches IDs rather than bundle positions. Callback processing passes the action index as u64, schedule reconstruction uses the mutable context and flattened undelegation indices, Solana dependency features are enabled, and test fixtures initialize BaseAction.id.

Suggested reviewers: GabrielePicco, snawaz, bmuddha

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/action-ids

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant