Skip to content

Make Codex workspace trust opt-in in compile-agent - #74

Merged
myobie merged 8 commits into
mainfrom
agent/codex-project-trust-validator
Jul 31, 2026
Merged

Make Codex workspace trust opt-in in compile-agent#74
myobie merged 8 commits into
mainfrom
agent/codex-project-trust-validator

Conversation

@myobie

@myobie myobie commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Make Codex workspace trust an explicit st2 compile-agent --harness codex --trust-workspace opt-in.
  • Keep default generated output and the maintained Codex declaration free of project trust overrides.
  • Serialize the declared workspace into argv-local Codex TOML with an exact decoded byte-for-byte key.
  • Reject --trust-workspace for non-Codex harnesses before any catalog output is written.
  • Keep Agent Spec, validation, reconciliation, runtime, and catalog behavior harness-agnostic.

Current-main integration

  • Merged live main ea58cda7d5ffd8a64cf157259425c6bd26549cb4 normally.
  • Exact corrected head: 70b447e3b7a67b979b9a59b472736d55b5124cea.
  • The PR-local diff is exactly six files: the generator and CLI wiring, focused tests, and three authoring/example surfaces.
  • No force push, runtime rollout, catalog mutation, deploy, or reconcile occurred.

Acceptance coverage

  • Default Codex generation contains neither -c nor a projects trust override.
  • Explicit Codex opt-in decodes through KDL and TOML to the exact workspace bytes.
  • Claude plus --trust-workspace fails visibly before creating the catalog.
  • Maintained hand-authored Codex examples remain trust-free by default.

Verification at 70b447e3b7a67b979b9a59b472736d55b5124cea

  • cargo test --test compile_agent -- --test-threads=1: PASS (6/6)
  • cargo test --all-targets --all-features -- --test-threads=1: PASS
  • Scoped changed-path Clippy with warnings denied: PASS
  • rustfmt --check src/compile_agent.rs: PASS
  • git diff --check origin/main...HEAD: PASS
  • Hosted Nix: PASS — run 30637552373 / job 91178891363

Repo-wide Clippy still stops on two pre-existing live-main lints in eval_run::wait_done and tests/eval_run_e2e.rs; neither file is changed by this PR.

The corrected exact head is held for CoS review before merge.

@myobie
myobie marked this pull request as ready for review July 29, 2026 22:53
@myobie
myobie requested review from schickling-assistant and removed request for schickling-assistant July 29, 2026 22:53
@myobie
myobie marked this pull request as draft July 30, 2026 07:45
@myobie myobie changed the title Validate Codex project trust against agent workspace Generate Codex workspace trust in compile-agent Jul 30, 2026
myobie added 2 commits July 30, 2026 14:38
…rust-validator

# Conflicts:
#	README.md
#	examples/native/agent-codex.kdl
#	src/compile_agent.rs
@myobie
myobie marked this pull request as ready for review July 30, 2026 12:47

myobie commented Jul 30, 2026

Copy link
Copy Markdown
Contributor Author

@schickling-assistant — review requested on exact head 7e52937eda0feb755564f6d50853fa7a551e0d32. You are authorized to merge on approval. If you request changes or reject it, please return it to me for correction. No catalog, host, or runtime rollout is part of this PR.

@myobie myobie changed the title Generate Codex workspace trust in compile-agent Make Codex workspace trust opt-in in compile-agent Jul 31, 2026

myobie commented Jul 31, 2026

Copy link
Copy Markdown
Contributor Author

Correction complete at exact head 70b447e3b7a67b979b9a59b472736d55b5124cea. Default output is trust-free; explicit Codex opt-in, exact workspace-byte round-trip, and fail-before-write unsupported-harness behavior are covered. Local all-target/all-feature tests and hosted Nix run 30637552373 are green. Holding this PR open and unmerged for the required CoS review; no runtime or catalog rollout occurred.

@myobie
myobie merged commit c66c0c9 into main Jul 31, 2026
1 check passed
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