Commit Graph
7025 Commits
Author SHA1 Message Date
Chris Bookholt 809d6129a3 test(git): allow platform-specific staging hook 2026-07-03 17:52:35 -07:00
Chris Bookholt 92d1967d21 fix(git): bind staging to repository authority 2026-07-03 17:31:39 -07:00
Chris Bookholt e674ac9a52 Merge branch 'codex/psec-4394-git-05a-apply-filters' into codex/psec-4394-git-05b-stage-filters 2026-07-02 12:07:12 -07:00
Chris Bookholt 80c59de030 Merge branch 'codex/psec-4394-repository-authority' into codex/psec-4394-git-05a-apply-filters 2026-07-02 12:06:50 -07:00
Chris Bookholt e8e8178e3a Merge branch 'codex/psec-4394-git-03-path-containment' into codex/psec-4394-repository-authority 2026-07-02 12:06:19 -07:00
Chris Bookholt f1c0d32986 Merge branch 'codex/psec-4394-git-02-effective-patch-paths' into codex/psec-4394-git-03-path-containment 2026-07-02 12:06:00 -07:00
Chris Bookholt 80d4da92f0 Merge branch 'codex/psec-4394-trusted-git-runner' into codex/psec-4394-git-02-effective-patch-paths 2026-07-02 12:05:45 -07:00
Chris Bookholt 63f6aa5da5 Merge branch 'bookholt/deny-transport-for-local-git' into codex/psec-4394-trusted-git-runner 2026-07-02 12:05:27 -07:00
Chris Bookholt 83e062ebaa Merge remote-tracking branch 'origin/main' into bookholt/deny-transport-for-local-git 2026-07-02 12:05:07 -07:00
Michael Bolin 0ccb676dd0 fix: address quick-xml security advisories (#30941)
## Why

The `cargo-deny` job on `main` began failing after
[RUSTSEC-2026-0194](https://rustsec.org/advisories/RUSTSEC-2026-0194)
and
[RUSTSEC-2026-0195](https://rustsec.org/advisories/RUSTSEC-2026-0195)
flagged the workspace `quick-xml 0.38.4`. Both denial-of-service issues
are fixed in `quick-xml 0.41.0`.

A `quick-xml 0.39.4` copy must temporarily remain because the latest
`plist` and `wayland-scanner` releases have not adopted 0.41 yet.
Neither retained path accepts attacker-controlled XML at runtime:
`plist` does not exercise the affected APIs, and `wayland-scanner`
parses trusted protocol definitions at build time. Compatible upstream
bumps are already open in
[rust-plist#191](https://github.com/ebarnard/rust-plist/pull/191) and
[wayland-rs#938](https://github.com/Smithay/wayland-rs/pull/938).

## What changed

- Upgrade the workspace `quick-xml` dependency used by `codex-protocol`
to 0.41.0.
- Refresh `Cargo.lock` and `MODULE.bazel.lock`; this also updates
`plist` to 1.9.0 and `wayland-scanner` to 0.31.10.
- Add synchronized, temporary `cargo-deny` and `cargo-audit` exceptions
for the trusted `quick-xml 0.39.4` paths, with both upstream releases
recorded as the removal condition.

## Testing

- `cargo deny check`
- `just test -p codex-protocol` (238 tests)
- `just bazel-lock-check`
2026-07-02 10:59:00 -07:00
Shijie Rao cbdd7f0047 Fix inherited availability metadata for Bedrock models (#30897)
## Why

Amazon Bedrock's static catalog derives its GPT model definitions from
bundled OpenAI model metadata. The GPT-5.6 variants introduced in #30285
clone GPT-5.5, which carries an `availability_nux`; because app-server
forwards that metadata through `model/list`, clients can show GPT-5.5
launch copy for a GPT-5.6 Bedrock model.

`upgrade` is also model-catalog availability metadata and should not be
inherited by provider-specific Bedrock models.

## What changed

- Clear `availability_nux` and `upgrade` when constructing static
Bedrock GPT models.
- Add a regression test asserting that every static Bedrock model omits
both fields.

## Testing

- `just test -p codex-model-provider`
2026-07-02 10:01:06 -07:00
Chris Bookholt 899d640254 ci(git-utils): shard unit tests 2026-07-02 08:02:20 -07:00
Chris Bookholt f047aa7f31 test(git-utils): isolate filter policy cardinality tests 2026-07-02 07:22:29 -07:00
Chris Bookholt 6da314e14f Merge operation-scoped config authorization into exact staging
# Conflicts:
#	codex-rs/git-utils/src/safe_git.rs
#	codex-rs/git-utils/src/safe_git_tests.rs
2026-07-02 06:51:31 -07:00
Chris Bookholt 30d7a76254 git-utils: scope config authorization to apply operations 2026-07-02 06:16:32 -07:00
Chris Bookholt 993d488f75 Merge apply-filter guard into exact staging guard 2026-07-02 05:18:32 -07:00
Chris Bookholt 53519625bd Merge repository-authority runner reuse into apply-filter guard 2026-07-02 05:04:35 -07:00
Chris Bookholt 10948913cd test(git-utils): gate Unix-only merge-base imports 2026-07-02 04:48:32 -07:00
xli-oai 6ff670bd03 [codex] emit per-request TTFT completion telemetry (#30883)
## Why

Codex telemetry pipeline needs a per-request TTFT value. The existing
`codex.turn_ttft` is recorded once per turn, so it cannot represent
later inference requests in the same turn and can miss the beginning of
hidden reasoning.

This restores the low-volume per-request signal proposed in
https://github.com/bk-nvidia/codex/pull/3 without bringing back
per-WebSocket-event TRACE logging.

## What changed

- start a timer when each mapped Responses stream begins
- latch the timer on the first `response.output_item.added`, including
an empty hidden-reasoning item
- attach `ttft_ms` to the existing `codex.sse_event` /
`response.completed` telemetry record
- cover the new completion field with an integration test

## Semantics

The value is per inference request, not per turn. It measures
mapped-stream-to-first-output-item latency, matching the
customer-proposed metric. For HTTP, the stream is already established
before timing begins, so request setup and response-header latency are
excluded.

`response.output_item.added` is a client-visible proxy for the start of
hidden reasoning; this does not claim access to the server's internal
first raw-token timestamp.

## Validation

- `just test -p codex-otel` (47 passed)
- `just test -p codex-core process_sse_emits_completed_telemetry` (1
passed after the final timer-placement change)
- attempted `just test -p codex-core`: 2,855 passed and 53 failed
because of unrelated local-environment failures (missing
`test_stdio_server` fixture binary, shell startup noise, and
timing-sensitive tests); the focused telemetry test passed in that run
as well
2026-07-02 04:45:03 -07:00
Chris Bookholt d43fab9464 fix(git-utils): reuse runner for merge-base 2026-07-02 04:33:41 -07:00
Chris Bookholt 7c0a4f4363 test(core): distinguish review timeout phases 2026-07-02 04:07:40 -07:00
Chris Bookholt fcd31e89a2 core: order review lifecycle entry before completion 2026-07-02 03:43:53 -07:00
Chris Bookholt 75f2ff379c test(core): surface review lifecycle failures 2026-07-02 02:52:07 -07:00
Chris Bookholt 2b8ce702a7 Merge commit '97dee6c2b8' into codex/psec-4394-git-05b-stage-filters 2026-07-02 01:58:57 -07:00
Chris Bookholt 97dee6c2b8 git-utils: fix Windows test import guards 2026-07-02 01:58:34 -07:00
Chris Bookholt 3e4c7d6380 Merge commit 'fab7d5a1e6aeebabdca0cea4dd09b5f9ad1a2d4e' into codex/psec-4394-git-05b-stage-filters 2026-07-02 01:42:45 -07:00
Chris Bookholt 34f1bb3ee0 git-utils: integrate exact staging with repository authority 2026-07-02 01:42:30 -07:00
Chris Bookholt fab7d5a1e6 git-utils: fix Windows authority and test fixtures 2026-07-02 01:33:44 -07:00
Chris Bookholt 5632dfd765 git-utils: support older Git boolean ranges 2026-07-02 01:01:44 -07:00
Chris Bookholt e8b30bd7d3 git-utils: integrate filter guards with repository authority 2026-07-02 00:46:29 -07:00
Chris Bookholt 801018897f Merge repository authority into apply filter guard 2026-07-02 00:16:26 -07:00
Chris Bookholt 7a4648aff4 git-utils: normalize junction fixture paths 2026-07-01 23:42:37 -07:00
Chris Bookholt 5a95b65f57 git-utils: gate Unix-only authority fixtures 2026-07-01 23:19:38 -07:00
Chris Bookholt 4430c51039 git-utils: fix Windows repository authority tests 2026-07-01 23:07:18 -07:00
Chris Bookholt 9c0e48eba6 git-utils: fix Windows repository authority checks 2026-07-01 22:27:54 -07:00
Chris Bookholt bf70395505 git-utils: make registry retarget test deterministic 2026-07-01 21:42:21 -07:00
Chris Bookholt daca14580c git-utils: fix Windows authority build 2026-07-01 21:30:49 -07:00
Chris Bookholt bcf026cbca git-utils: centralize repository authority and trusted Git launch 2026-07-01 21:19:17 -07:00
Chris Bookholt 17f491ab67 git-utils: stage patch paths without recursive add 2026-07-01 18:57:30 -07:00
Michael Bolin 129ea2aaf5 Log multi-agent communication lifecycle (#30872)
## Why

[#30867](https://github.com/openai/codex/pull/30867) makes
`submit_inter_agent_communication` the common outbound sink for
multi-agent v2 communications. This follow-up uses that single point to
log every communication lifecycle without requiring new hooks as spawn,
messaging, follow-up, or result paths evolve.

For each communication, the logs need to identify its type, sender and
receiver threads, and content, while correlating the successful send
with receipt by the destination mailbox. The logging path must not query
externally supplied time providers because those calls can be expensive
for app-server clients.

## What changed

- Added structured `INFO` events on the OpenTelemetry-exported
`codex_otel.agent_communication` target for `spawn`, `message`,
`followup`, and `result` communications.
- Logged successful sends from `submit_inter_agent_communication` with
the communication kind, sender and receiver thread IDs, content, and
submission ID.
- Logged receives after the communication has been enqueued in the
receiver mailbox, using the same submission ID.
- Avoided time-provider calls and other asynchronous work in the logging
path.
- Narrowed ordinary spawn and send-input APIs to `Vec<UserInput>` so
`Op::InterAgentCommunication` cannot bypass the context-bearing
centralized path.

The refactor does not change submission IDs, capacity checks, last-task
bookkeeping, mailbox ordering, protocol types, rollout data, or
model-visible context.

## Event shape

Illustrative JSON representation of the two independently emitted
records:

```json
[
  {
    "event.name": "codex.agent_communication",
    "communication_id": "019f20e1-40d1-7890-a123-456789abcdef",
    "kind": "spawn",
    "state": "send",
    "sender_thread_id": "019f20df-fbe1-7890-a123-456789abcdef",
    "receiver_thread_id": "019f20e1-3f79-7890-a123-456789abcdef",
    "content": "inspect the repository"
  },
  {
    "event.name": "codex.agent_communication",
    "communication_id": "019f20e1-40d1-7890-a123-456789abcdef",
    "state": "receive"
  }
]
```

Consumers join the receive record to the send record by
`communication_id` for the immutable communication metadata.

## Testing

- Extended the existing end-to-end multi-agent v2 spawn test to verify
content, both thread IDs, and a correlated send/receive submission ID.
- Re-ran focused control and handler coverage for direct messages,
follow-up tasks, and completion results.
2026-07-01 18:11:09 -07:00
Michael Bolin a98a21798c Consolidate multi-agent v2 communication sends (#30867)
## Why

Multi-agent v2 communications currently use separate outbound paths:
direct messages, follow-up tasks, and completion results go through
`send_inter_agent_communication`, while a spawn's initial message goes
through the generic input submission path. That split makes it difficult
to add complete communication lifecycle logging in one place.

This refactor makes `submit_inter_agent_communication` the common sink
for those paths, preparing the follow-up observability work discussed in
[#30516](https://github.com/openai/codex/pull/30516).

## What changed

- Routed all current outbound `InterAgentCommunication` paths in
`AgentControl`—direct messages, follow-up tasks, completion results, and
multi-agent v2 spawn initial messages—through
`submit_inter_agent_communication`.
- Centralized the actual submission and last-task-message bookkeeping
there, providing one place for the follow-up PR to instrument
communication creation and successful enqueue.
- Left non-communication input handling and the multi-agent v1 spawn
flow unchanged.

## Testing

- `just test -p codex-core 'agent::control::tests::'` (51 passed)
- `just test -p codex-core
'suite::subagent_notifications::encrypted_multi_agent_v2_spawn_sends_agent_message_to_child'`
(passed)








---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/openai/codex/pull/30867).
* #30872
* __->__ #30867
2026-07-01 17:08:11 -07:00
Chris Bookholt 9a21b607e3 Merge branch 'codex/psec-4394-git-02-effective-patch-paths' into codex/psec-4394-git-03-path-containment 2026-07-01 16:50:50 -07:00
Chris Bookholt f303ab00da Merge commit '300bbcbf5c' into codex/psec-4394-git-02-effective-patch-paths 2026-07-01 16:50:46 -07:00
Chris Bookholt 300bbcbf5c git-utils: clarify raw PATH rejection 2026-07-01 16:50:40 -07:00
Chris Bookholt efbd215b81 Merge branch 'codex/psec-4394-git-02-effective-patch-paths' into codex/psec-4394-git-03-path-containment 2026-07-01 16:49:45 -07:00
Chris Bookholt 1ea2e7fcc4 Merge commit 'edda59a703' into codex/psec-4394-git-02-effective-patch-paths 2026-07-01 16:49:32 -07:00
Chris Bookholt edda59a703 git-utils: fix Windows traversal regression test 2026-07-01 16:49:19 -07:00
Chris Bookholt d98e980a31 git-utils: scope filter test helpers to tests 2026-07-01 16:34:53 -07:00
Chris Bookholt f2874f80f9 Merge branch 'codex/psec-4394-git-05a-apply-filters' into codex/psec-4394-git-05b-stage-filters 2026-07-01 16:21:28 -07:00
Chris Bookholt 68da17b9d8 Merge branch 'codex/psec-4394-git-03-path-containment' into codex/psec-4394-git-05a-apply-filters 2026-07-01 16:21:13 -07:00