Skip to content

Route apply_patch through the environment filesystem#17674

Merged
starr-openai merged 11 commits intomainfrom
starr/apply-patch-envfs-agent3-20260413
Apr 14, 2026
Merged

Route apply_patch through the environment filesystem#17674
starr-openai merged 11 commits intomainfrom
starr/apply-patch-envfs-agent3-20260413

Conversation

@starr-openai
Copy link
Copy Markdown
Contributor

Summary

  • route apply_patch runtime execution through the selected Environment filesystem instead of the local self-exec path
  • keep the standalone apply_patch command surface intact while restoring its launcher/test/docs contract
  • add focused apply_patch filesystem sandbox regression coverage

Validation

  • remote devbox Bazel run in progress
  • passed: //codex-rs/apply-patch:apply-patch-unit-tests --test_filter=test_read_file_utf8_with_context_reports_invalid_utf8
  • in progress / follow-up: focused core and exec Bazel test slices on dev

Follow-up under review

  • remote pre-verification and approval/retry behavior still need explicit scrutiny for delete/update flows
  • runtime sandbox-denial classification may need a tighter assertion path than rendered stderr matching

starr-openai added a commit that referenced this pull request Apr 13, 2026
Co-authored-by: Codex <noreply@openai.com>
starr-openai added a commit that referenced this pull request Apr 13, 2026
Co-authored-by: Codex <noreply@openai.com>
Comment thread codex-rs/apply-patch/tests/fs_sandbox.rs Outdated
Comment thread codex-rs/arg0/src/lib.rs Outdated
starr-openai added a commit that referenced this pull request Apr 13, 2026
Co-authored-by: Codex <noreply@openai.com>
starr-openai added a commit that referenced this pull request Apr 13, 2026
Co-authored-by: Codex <noreply@openai.com>
starr-openai added a commit that referenced this pull request Apr 13, 2026
Co-authored-by: Codex <noreply@openai.com>
@starr-openai starr-openai marked this pull request as ready for review April 13, 2026 21:42
starr-openai and others added 8 commits April 13, 2026 16:55
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: Codex <noreply@openai.com>
@starr-openai starr-openai force-pushed the starr/apply-patch-envfs-agent3-20260413 branch from a0fbf33 to d595a3f Compare April 13, 2026 23:55
Comment thread codex-rs/core/tests/suite/mod.rs Outdated
Comment thread codex-rs/apply-patch/src/invocation.rs Outdated
Comment thread codex-rs/apply-patch/src/lib.rs
Comment thread codex-rs/core/src/tools/runtimes/apply_patch.rs
Comment thread codex-rs/core/src/tools/runtimes/apply_patch_tests.rs
Comment thread codex-rs/apply-patch/src/lib.rs
starr-openai and others added 3 commits April 13, 2026 17:50
Co-authored-by: Codex <noreply@openai.com>
Only create parent directories when the parent is actually missing so file-level approvals do not trip on existing parent directories.

Co-authored-by: Codex <noreply@openai.com>
Attempt the write before creating parent directories so file-scoped approvals do not require a separate parent-directory metadata probe.

Co-authored-by: Codex <noreply@openai.com>
@starr-openai starr-openai requested a review from pakrym-oai April 14, 2026 17:08
@starr-openai starr-openai merged commit c24124b into main Apr 14, 2026
40 of 46 checks passed
@starr-openai starr-openai deleted the starr/apply-patch-envfs-agent3-20260413 branch April 14, 2026 19:49
@github-actions github-actions bot locked and limited conversation to collaborators Apr 14, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants