Repository navigation
feat(messaging): add read-only existing-session resume preflight #8273
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
4440d3e
9f6e7b6
a48d40c
9703493
4d2c525
82a56f3
b1f1609
0f4c012
11b8dc6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -47,7 +47,7 @@ Windows is explicitly refused. | |
| to 16 KiB; NUL and empty text are refused. There is no name guessing, model | ||
| override, permission grant or automatic response. | ||
|
|
||
| Each tool call starts a short-lived, explicitly selected Codex CLI app-server | ||
| Each queue/metadata or stored-read tool call starts a short-lived, explicitly selected Codex CLI app-server | ||
| over stdio. It uses `thread/list` or the same experimental `thread/queue/add` | ||
| method as `codex queue`, without putting text in subprocess arguments. It issues | ||
| no daemon-start, login, thread-resume, turn-start or steer request. Ordinary | ||
|
|
@@ -433,3 +433,41 @@ is not controlled by it. | |
|
|
||
| Mesh, dashboard/cache controls, isolation, Claude messaging, managed skills and | ||
| idle notifications remain outside this contribution. | ||
|
|
||
|
|
||
| ## Explicit existing-server resume | ||
|
|
||
| **Execution is currently blocked pending native atomic conditional resume support.** | ||
| This pending tool cannot safely resume an unloaded conversation with the checked | ||
| Codex 0.166.0 API. It performs bounded preflight and returns a refusal; it does not | ||
| run queued work. Existing queue and stored-reply tools remain available separately. | ||
|
|
||
| To expose the preflight tool, configure all three arguments: | ||
|
|
||
| ```sh | ||
| ocx message mcp --codex /absolute/path/to/codex --codex-home /absolute/path/to/.codex --allow-reply-read --allow-resume --resume-socket /absolute/path/to/existing.sock --resume-permissions :read-only | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Remove the unrelated reply-read grant. A user who copies this command to enable preflight also enables
|
||
| ``` | ||
|
|
||
| The socket must be an existing trusted local Unix App Server reporting the same | ||
| canonical Codex home. No server is installed or started. An exact thread UUID is | ||
| normalized before metadata-only lookup. Observed loaded idle/active targets return | ||
| `already_loaded`; unhealthy targets refuse. For an unloaded target, managed policy, | ||
| unsupported APIs, invalid metadata or a missing/disallowed/unobserved profile refuse. | ||
| The profile is configured by the host, never by tool arguments or queued messages. | ||
| The check reads one bounded catalog page of at most 50 profiles in the target cwd. | ||
|
|
||
| Even when these checks pass, the result is `not_resumed` with | ||
| `resume_atomicity_unsupported`. No `thread/resume` is sent. Another client could load | ||
| and unsubscribe from the conversation between the metadata read and resume; the | ||
| checked native server can replace that idle cache entry using supplied permissions. | ||
| A client-side lock or second read cannot eliminate this window. Execution requires | ||
| a native unloaded-only condition enforced atomically before changing a live thread; | ||
| there is no supported conditional-resume API in the checked version. Do not bypass | ||
| this refusal, infer safety from a version string or treat an acknowledgement as a | ||
| way to undo work already started. | ||
|
|
||
| `executionVerified` is always false. The tool starts no conversation or turn, | ||
| changes no permission and answers no approval requests. Each call shares a | ||
| 20-second budget and the host's four-operation limit; overlapping calls for one | ||
| UUID refuse. Disconnect closes only the bridge connection. Network/SSH endpoints | ||
| and Windows remain outside this tool's scope. | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Document how to call the preflight tool.
This section does not name
codex_resume_threador its requiredthreadIdinput. Readers must inspect the MCP tool list before they can use the preflight. Add the name and an input example here and in the Turkish reference. (raw.githubusercontent.com)