Skip to content

Checkpoint runtime-committed session projections#733

Merged
lukacf merged 1 commit into
mainfrom
codex/runtime-committed-session-projection
May 19, 2026
Merged

Checkpoint runtime-committed session projections#733
lukacf merged 1 commit into
mainfrom
codex/runtime-committed-session-projection

Conversation

@lukacf
Copy link
Copy Markdown
Owner

@lukacf lukacf commented May 19, 2026

Summary

  • add a post-machine-commit CoreExecutor hook for committed session snapshots
  • have the mob runtime executor save runtime-committed snapshots back to the SessionStore projection
  • add runtime ordering/failure tests and a persistent-service projection regression test

Why

0.6.18 made StoreCheckpointer save-capable for runtime-backed sessions, but the MeerkatMachine-owned runtime loop committed turns through RuntimeStore without invoking the SessionStore projection save path. This wires the projection update after the machine commit succeeds, avoiding a pre-commit split-brain while restoring per-turn SessionStore saves for MobKit/UnifiedRuntime consumers.

Tests

  • ./scripts/repo-cargo fmt --check
  • ./scripts/repo-cargo test -p meerkat-runtime runtime_loop_checkpoint -- --nocapture
  • ./scripts/repo-cargo test -p meerkat-session --features session-store checkpoint_updates_session_store_projection -- --nocapture
  • ./scripts/repo-cargo test -p meerkat-session --features session-store store_checkpointer -- --nocapture
  • ./scripts/repo-cargo test -p meerkat-mob checkpoint_committed -- --nocapture
  • git diff --check

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b09b4834b2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

&mut self,
_session_snapshot: &[u8],
) -> Result<(), CoreExecutorError> {
Ok(())
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Wire checkpoint hook for non-mob executors

When runtime-backed sessions run through the existing REST/MCP/CLI/RPC executors, those executors return CoreApplyOutput from PersistentSessionService::apply_runtime_turn but do not override this new hook, so the runtime loop calls this default Ok(()) after the machine commit and the SessionStore projection is never updated. I checked meerkat-rest/src/lib.rs, meerkat-mcp-server/src/runtime_ingress.rs, meerkat/src/surface/runtime_backed.rs, and meerkat-rpc/src/session_executor.rs; only MobSessionRuntimeExecutor delegates to checkpoint_committed_runtime_session_snapshot, leaving those production surfaces with stale persisted projections after each committed turn.

Useful? React with 👍 / 👎.

@lukacf lukacf merged commit 4f8f8a0 into main May 19, 2026
18 checks passed
@lukacf lukacf deleted the codex/runtime-committed-session-projection branch May 19, 2026 09:31
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