Skip to content

Serialize execute_code sessions per bot#47

Open
MaxBittker wants to merge 1 commit into
mainfrom
codex/mcp-execution-minimal
Open

Serialize execute_code sessions per bot#47
MaxBittker wants to merge 1 commit into
mainfrom
codex/mcp-execution-minimal

Conversation

@MaxBittker

Copy link
Copy Markdown
Owner

Summary

  • run execute_code in a per-bot FIFO while allowing different bots to proceed concurrently
  • stop timed-out or cancelled programs from starting new SDK calls
  • keep the bot lock until SDK calls that already started have settled
  • use a request-scoped console so concurrent sessions do not overwrite process globals, while routing SDK diagnostics away from MCP stdout
  • preserve TypeScript bodies, bounded logs, partial error output, and the terminal world-state snapshot

Deliberately omitted from #44

No structured inspect/query/action tools, session-health metadata, resource abstraction, connection-manager rewrite, or separate output framework. This is the smallest slice that prevents agent programs from interleaving mutations.

Validation

Boundary

execute_code remains trusted, unsandboxed execution. CPU-bound synchronous code cannot be pre-empted. An SDK call that already started cannot be force-aborted, so the next same-bot session intentionally waits for it to settle.

Supersedes #44.

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