mirror of
https://github.com/openai/codex.git
synced 2026-11-22 23:00:42 +00:00
Move workspace roots onto thread/session state and stop using active permission profile modifications as an overlay for writable roots. Existing app-server threads now preserve their persisted PermissionProfile value across resume, fork, and turn updates; permissions requests on existing threads only update the active named profile after validating it exists. Workspace roots can be updated independently, and SandboxPolicy::WorkspaceWrite no longer stores its own writable_roots.
This commit is contained in:
@@ -309,6 +309,7 @@ mod tests {
|
||||
permission_profile: PermissionProfile::read_only(),
|
||||
active_permission_profile: None,
|
||||
cwd: test_path_buf("/home/user/project").abs(),
|
||||
workspace_roots: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffort::default()),
|
||||
initial_messages: None,
|
||||
network_proxy: None,
|
||||
@@ -354,6 +355,7 @@ mod tests {
|
||||
permission_profile: PermissionProfile::read_only(),
|
||||
active_permission_profile: None,
|
||||
cwd: test_path_buf("/home/user/project").abs(),
|
||||
workspace_roots: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffort::default()),
|
||||
initial_messages: None,
|
||||
network_proxy: None,
|
||||
@@ -392,6 +394,7 @@ mod tests {
|
||||
"approvals_reviewer": "user",
|
||||
"permission_profile": session_configured_event.permission_profile,
|
||||
"cwd": test_path_buf("/home/user/project"),
|
||||
"workspace_roots": [],
|
||||
"reasoning_effort": session_configured_event.reasoning_effort,
|
||||
"rollout_path": rollout_file.path().to_path_buf(),
|
||||
}
|
||||
@@ -421,6 +424,7 @@ mod tests {
|
||||
permission_profile: PermissionProfile::read_only(),
|
||||
active_permission_profile: None,
|
||||
cwd: test_path_buf("/home/user/project").abs(),
|
||||
workspace_roots: Vec::new(),
|
||||
reasoning_effort: Some(ReasoningEffort::default()),
|
||||
initial_messages: None,
|
||||
network_proxy: None,
|
||||
@@ -460,6 +464,7 @@ mod tests {
|
||||
"approvals_reviewer": "user",
|
||||
"permission_profile": session_configured_event.permission_profile,
|
||||
"cwd": test_path_buf("/home/user/project"),
|
||||
"workspace_roots": [],
|
||||
"reasoning_effort": session_configured_event.reasoning_effort,
|
||||
"rollout_path": rollout_file.path().to_path_buf(),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user