Commit Graph

10791 Commits

Author SHA1 Message Date
Michael Bolin
a033db45d6 merge commit for archive created by Sapling 2026-04-01 08:40:17 -07:00
Michael Bolin
8f109fa65a docs: update argument_comment_lint instructions in AGENTS.md 2026-04-01 08:39:53 -07:00
Dylan Hurd
d3b99ef110 fix(core) rm execute_exec_request sandbox_policy (#16422)
## Summary
In #11871 we started consolidating on ExecRequest.sandbox_policy instead
of passing in a separate policy object that theoretically could differ
(but did not). This finishes the some parameter cleanup.

This should be a simple noop, since all 3 callsites of this function
already used a cloned object from the ExecRequest value.

## Testing
- [x] Existing tests pass
2026-04-01 11:03:48 -04:00
jif-oai
f839f3ff2e feat: auto vaccum state DB (#16434)
Start with a full vaccum the first time, then auto-vaccum incremental
2026-04-01 16:46:21 +02:00
jif-oai
c846a57d03 chore: drop log DB (#16433)
Drop the log table from the state DB
2026-04-01 15:49:17 +02:00
jif-oai
5bbfee69b6 nit: deny field v2 (#16427) 2026-04-01 12:26:40 +02:00
jif-oai
609ac0c7ab chore: interrupted as state (#16426) 2026-04-01 12:26:29 +02:00
jif-oai
df5f79da36 nit: update wait v2 desc (#16425) 2026-04-01 12:26:25 +02:00
jif-oai
0c776c433b feat: tasks can't be assigned to root agent (#16424) 2026-04-01 12:18:50 +02:00
jif-oai
3152d1a557 Use message string in v2 assign_task (#16419)
Fix assign task and clean everything

---------

Co-authored-by: Codex <noreply@openai.com>
2026-04-01 11:40:19 +02:00
jif-oai
23d638a573 Use message string in v2 send_message (#16409)
## Summary
- switch MultiAgentV2 send_message to accept a single message string
instead of items
- keep the old assign_task item parser in place for the next branch
- update send_message schema/spec and focused handler tests

## Verification
- cargo test -p codex-tools
send_message_tool_requires_message_and_uses_submission_output
- cargo test -p codex-core multi_agent_v2_send_message
- just fix -p codex-tools
- just fix -p codex-core
- just argument-comment-lint

---------

Co-authored-by: Codex <noreply@openai.com>
2026-04-01 11:26:22 +02:00
jif-oai
d0474f2bc1 Use message string in v2 spawn_agent (#16406)
## Summary
- switch MultiAgentV2 spawn_agent to accept a single message string
instead of items
- update v2 spawn tool schema and focused handler/spec tests

## Verification
- cargo test -p codex-tools
spawn_agent_tool_v2_requires_task_name_and_lists_visible_models
- cargo test -p codex-core multi_agent_v2_spawn
- just fix -p codex-tools
- just fix -p codex-core
- just argument-comment-lint

Co-authored-by: Codex <noreply@openai.com>
2026-04-01 11:26:12 +02:00
Michael Bolin
ba66c0fd20 Merge 8b1464f252 into sapling-pr-archive-bolinfest 2026-03-31 17:40:51 -07:00
Michael Bolin
8b1464f252 core: split large async hot paths out of codex.rs 2026-03-31 17:40:38 -07:00
Michael Bolin
c3f901c4cb Merge 5c3db6d578 into sapling-pr-archive-bolinfest 2026-03-31 17:38:43 -07:00
Michael Bolin
5c3db6d578 Extract tool config into codex-tools 2026-03-31 17:38:37 -07:00
Michael Bolin
dedd1c386a fix: suppress status card expect_used warnings after #16351 (#16378)
## Why

Follow-up to #16351.

That PR synchronized Bazel clippy lint levels with Cargo, but two
intentional `expect()` calls in `codex-rs/tui/src/status/card.rs` still
tripped `clippy::expect_used` (I believe #16201 raced with #16351, which
is why it was missed).
2026-03-31 17:38:26 -07:00
Michael Bolin
b80e57aef3 Merge ba8176b3b7 into sapling-pr-archive-bolinfest 2026-03-31 17:29:59 -07:00
Michael Bolin
89db1077a0 Merge f6aac79202 into sapling-pr-archive-bolinfest 2026-03-31 17:29:26 -07:00
Michael Bolin
f6aac79202 fix: suppress clippy violations that raced with #16351 2026-03-31 17:29:21 -07:00
Michael Bolin
2c4f49f6fb Merge 201fc3847b into sapling-pr-archive-bolinfest 2026-03-31 17:25:36 -07:00
Michael Bolin
201fc3847b fix: suppress clippy violations that raced with #16351 2026-03-31 17:25:29 -07:00
Michael Bolin
ba8176b3b7 Extract tool config into codex-tools 2026-03-31 17:12:11 -07:00
Michael Bolin
2e942ce830 ci: sync Bazel clippy lints and fix uncovered violations (#16351)
## Why

Follow-up to #16345, the Bazel clippy rollout in #15955, and the cleanup
pass in #16353.

`cargo clippy` was enforcing the workspace deny-list from
`codex-rs/Cargo.toml` because the member crates opt into `[lints]
workspace = true`, but Bazel clippy was only using `rules_rust` plus
`clippy.toml`. That left the Bazel lane vulnerable to drift:
`clippy.toml` can tune lint behavior, but it cannot set
allow/warn/deny/forbid levels.

This PR now closes both sides of the follow-up. It keeps `.bazelrc` in
sync with `[workspace.lints.clippy]`, and it fixes the real clippy
violations that the newly-synced Windows Bazel lane surfaced once that
deny-list started matching Cargo.

## What Changed

- added `.github/scripts/verify_bazel_clippy_lints.py`, a Python check
that parses `codex-rs/Cargo.toml` with `tomllib`, reads the Bazel
`build:clippy` `clippy_flag` entries from `.bazelrc`, and reports
missing, extra, or mismatched lint levels
- ran that verifier from the lightweight `ci.yml` workflow so the sync
check does not depend on a Rust toolchain being installed first
- expanded the `.bazelrc` comment to explain the Cargo `workspace =
true` linkage and why Bazel needs the deny-list duplicated explicitly
- fixed the Windows-only `codex-windows-sandbox` violations that Bazel
clippy reported after the sync, using the same style as #16353: inline
`format!` args, method references instead of trivial closures, removed
redundant clones, and replaced SID conversion `unwrap` and `expect`
calls with proper errors
- cleaned up the remaining cross-platform violations the Bazel lane
exposed in `codex-backend-client` and `core_test_support`

## Testing

Key new test introduced by this PR:

`python3 .github/scripts/verify_bazel_clippy_lints.py`
2026-03-31 17:09:48 -07:00
Michael Bolin
c980215c2c Merge d7aa3eecf2 into sapling-pr-archive-bolinfest 2026-03-31 16:38:02 -07:00
Michael Bolin
d7aa3eecf2 docs: update argument_comment_lint instructions in AGENTS.md 2026-03-31 16:37:47 -07:00
Eric Traut
ae057e0bb9 Fix stale /status rate limits in active TUI sessions (#16201)
Fix stale weekly limit in `/status` (#16194): /status reused the
session’s cached rate-limit snapshot, so the weekly remaining limit
could stay frozen within an active session.

With this change, we now dynamically update the rate limits after status
is displayed.

I needed to delete a few low-value test cases from the chatWidget tests
because the test.rs file is really large, and the new tests in this PR
pushed us over the 512K mandated limit. I'm working on a separate PR to
refactor that test file.
2026-03-31 17:03:05 -06:00
Eric Traut
424e532a6b Refactor chatwidget tests into topical modules (#16361)
Problem: `chatwidget/tests.rs` had grown into a single oversized test
blob that was hard to maintain and exceeded the repo's blob size limit.

Solution: split the chatwidget tests into topical modules with a thin
root `tests.rs`, shared helper utilities, preserved snapshot naming, and
hermetic test config so the refactor stays stable and passes the
`codex-tui` test suite.
2026-03-31 16:45:58 -06:00
Michael Bolin
ca3d36bc60 merge commit for archive created by Sapling 2026-03-31 15:36:28 -07:00
Michael Bolin
a1f9eda176 ci: sync Bazel clippy lints and fix uncovered violations 2026-03-31 15:36:14 -07:00
Michael Bolin
d560ed70a8 Merge b7d5f40280 into sapling-pr-archive-bolinfest 2026-03-31 15:14:50 -07:00
Michael Bolin
b7d5f40280 ci: sync Bazel clippy lints and fix uncovered violations 2026-03-31 15:14:19 -07:00
Michael Bolin
28873317f4 Merge d689bb5e32 into sapling-pr-archive-bolinfest 2026-03-31 15:13:36 -07:00
Michael Bolin
d689bb5e32 ci: sync Bazel clippy lints and fix uncovered violations 2026-03-31 15:13:29 -07:00
Michael Bolin
9a8730f31e ci: verify codex-rs Cargo manifests inherit workspace settings (#16353)
## Why

Bazel clippy now catches lints that `cargo clippy` can still miss when a
crate under `codex-rs` forgets to opt into workspace lints. The concrete
example here was `codex-rs/app-server/tests/common/Cargo.toml`: Bazel
flagged a clippy violation in `models_cache.rs`, but Cargo did not
because that crate inherited workspace package metadata without
declaring `[lints] workspace = true`.

We already mirror the workspace clippy deny list into Bazel after
[#15955](https://github.com/openai/codex/pull/15955), so we also need a
repo-side check that keeps every `codex-rs` manifest opted into the same
workspace settings.

## What changed

- add `.github/scripts/verify_cargo_workspace_manifests.py`, which
parses every `codex-rs/**/Cargo.toml` with `tomllib` and verifies:
  - `version.workspace = true`
  - `edition.workspace = true`
  - `license.workspace = true`
  - `[lints] workspace = true`
- top-level crate names follow the `codex-*` / `codex-utils-*`
conventions, with explicit exceptions for `windows-sandbox-rs` and
`utils/path-utils`
- run that script in `.github/workflows/ci.yml`
- update the current outlier manifests so the check is enforceable
immediately
- fix the newly exposed clippy violations in the affected crates
(`app-server/tests/common`, `file-search`, `feedback`,
`shell-escalation`, and `debug-client`)






---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/openai/codex/pull/16353).
* #16351
* __->__ #16353
2026-03-31 21:59:28 +00:00
Michael Bolin
04ec9ef8af Fix Windows external bearer refresh test (#16366)
## Why

https://github.com/openai/codex/pull/16287 introduced a change to
`codex-rs/login/src/auth/auth_tests.rs` that uses a PowerShell helper to
read the next token from `tokens.txt` and rewrite the remainder back to
disk. On Windows, `Get-Content` can return a scalar when the file has
only one remaining line, so `$lines[0]` reads the first character
instead of the full token. That breaks the external bearer refresh test
once the token list is nearly exhausted.

https://github.com/openai/codex/pull/16288 introduced similar changes to
`codex-rs/core/src/models_manager/manager_tests.rs` and
`codex-rs/core/tests/suite/client.rs`.

These went unnoticed because the failures showed up when the test was
run via Cargo on Windows, but not in our Bazel harness. Figuring out
that Cargo-vs-Bazel delta will happen in a follow-up PR.

## Verification

On my Windows machine, I verified `cargo test` passes when run in
`codex-rs/login` and `codex-rs/core`. Once this PR is merged, I will
keep an eye on
https://github.com/openai/codex/actions/workflows/rust-ci-full.yml to
verify it goes green.

## What changed

- Wrap `Get-Content -Path tokens.txt` in `@(...)` so the script always
gets array semantics before counting, indexing, and rewriting the
remaining lines.
2026-03-31 14:44:54 -07:00
Michael Bolin
847dbd1c26 merge commit for archive created by Sapling 2026-03-31 14:34:50 -07:00
Michael Bolin
d0f053c39b ci: verify codex-rs Cargo manifests inherit workspace settings 2026-03-31 14:34:31 -07:00
Michael Bolin
b9e6f8f440 ci: verify Bazel clippy lints stay synced with Cargo workspace 2026-03-31 14:34:31 -07:00
Michael Bolin
308cb3006e Merge d4f97462a6 into sapling-pr-archive-bolinfest 2026-03-31 14:22:14 -07:00
Michael Bolin
d4f97462a6 ci: verify Bazel clippy lints stay synced with Cargo workspace 2026-03-31 14:22:07 -07:00
Michael Bolin
1707cd523a ci: verify codex-rs Cargo manifests inherit workspace settings 2026-03-31 14:22:07 -07:00
Michael Bolin
bc38a59393 merge commit for archive created by Sapling 2026-03-31 14:08:04 -07:00
Michael Bolin
1f748b1fe8 ci: verify Bazel clippy lints stay synced with Cargo workspace 2026-03-31 14:07:54 -07:00
Michael Bolin
af3f6cbfb7 ci: verify codex-rs Cargo manifests inherit workspace settings 2026-03-31 14:07:54 -07:00
Michael Bolin
aefa684b80 merge commit for archive created by Sapling 2026-03-31 14:04:01 -07:00
Michael Bolin
5565515429 ci: verify Bazel clippy lints stay synced with Cargo workspace 2026-03-31 14:03:42 -07:00
Michael Bolin
b977dc96dc ci: verify codex-rs Cargo manifests inherit workspace settings 2026-03-31 14:03:42 -07:00
Eric Traut
103acdfb06 Refactor external auth to use a single trait (#16356)
## Summary
- Replace the separate external auth enum and refresher trait with a
single `ExternalAuth` trait in login auth flow
- Move bearer token auth behind `BearerTokenRefresher` and update
`AuthManager` and app-server wiring to use the generic external auth API
2026-03-31 14:54:18 -06:00
Eric Traut
0fe873ad5f Fix PR babysitter review comment monitoring (#16363)
## Summary
- prioritize newly surfaced review comments ahead of CI and mergeability
handling in the PR babysitter watcher
- keep `--watch` running for open PRs even when they are currently
merge-ready so later review feedback is not missed
2026-03-31 14:25:32 -06:00