[codex] Carry exec-server cwd as PathUri (#28032)

## Why

This is the second-to-last place in the exec-server protocol that needs
to migrate to URIs to support cross-OS operation.

## What

- Change `ExecParams.cwd` to `PathUri`.
- Keep the cwd URI-shaped through core and rmcp producers, converting it
to `AbsolutePathBuf` only in `LocalProcess::start_process`.
- Reject non-native cwd URIs before launch and update the affected
protocol documentation and call sites.
This commit is contained in:
Adam Perry @ OpenAI
2026-06-13 13:56:42 -07:00
committed by GitHub
Unverified
parent 17586d80ee
commit 0fed4497f5
13 changed files with 84 additions and 85 deletions
+2 -1
View File
@@ -195,6 +195,7 @@ mod tests {
use codex_app_server_protocol::JSONRPCRequest;
use codex_app_server_protocol::JSONRPCResponse;
use codex_app_server_protocol::RequestId;
use codex_utils_path_uri::PathUri;
use serde::Serialize;
use serde::de::DeserializeOwned;
use tokio::io::AsyncBufReadExt;
@@ -396,7 +397,7 @@ mod tests {
ExecParams {
process_id,
argv: sleep_then_print_argv(),
cwd: std::env::current_dir().expect("cwd"),
cwd: PathUri::from_path(std::env::current_dir().expect("cwd")).expect("cwd URI"),
env_policy: None,
env,
tty: false,