Commit Graph

8411 Commits

Author SHA1 Message Date
zsol-openai
7982aa27ff Allow numer in codespell checks (#34516)
## What changed

Add `numer`, the Symphonia time-base numerator field used during audio
duration calculation, to `.codespellignore`.

GitOrigin-RevId: b2f78772d8eb7c40150cf062eb9310b0138cfd03
2026-07-21 10:57:56 +00:00
zsol-openai
765675a122 Add an optional releases.openai.com installer source (#34514)
## What changed

- Let the shell and PowerShell installers resolve metadata and download assets from `releases.openai.com` when `CODEX_INSTALLER_USE_RELEASES_OPENAI_COM` is enabled.
- Fall back to GitHub Releases when metadata or asset downloads from the alternate source are unavailable.
- Verify that an installed or cached Codex binary reports the resolved version before activating it.

## Testing

- Cover latest-release installation, asset fallback, mismatched binary versions, and reuse of a cached legacy package in the shell installer tests.

GitOrigin-RevId: 48c57d3377fbc6b0903570c665041bb465ca6f4c
2026-07-21 10:38:44 +00:00
Michael Bolin
d937bfac84 Honor system proxy settings for remote plugins (#34509)
## Why

Remote plugin requests did not use Codex's effective outbound proxy policy, so
they could bypass configured system proxy and PAC routing.

## What changed

- Route remote plugin catalog, mutation, sharing, upload, and bundle download
  requests through the configured route-aware HTTP client.
- Select routes using the complete request URL, including encoded query
  parameters and backend-provided signed upload or download URLs.
- Preserve standard Codex headers and suppress diagnostics for URLs or headers
  that may contain credentials.

## Testing

Add coverage for route selection of catalog queries, workspace plugin uploads,
and backend-provided bundle download URLs.

GitOrigin-RevId: 106936659e21decf145b6ab4d4be84992e386861
2026-07-21 10:05:06 +00:00
zsol-openai
a148e0b50a Publish release metadata to R2 channels (#34508)
## What changed

- Publish the verified `release.json` metadata to `codex/channels/latest` for
  stable releases and `codex/channels/prerelease` for prereleases.
- Pass the release classification through the reusable R2 workflow so GitHub
  Releases and R2 channels use the same stable-versus-prerelease decision.
- Allow channel objects to be replaced while keeping versioned release objects
  immutable, and verify each channel upload before completing the publication.

GitOrigin-RevId: bd5c728c5565befe42b041ee1a032b111daca1c2
2026-07-21 09:55:09 +00:00
Michael Bolin
94bb6a09a6 Respect system proxies during plugin startup sync (#34506)
## Why

The curated plugin startup sync can fall back from Git to HTTP, but those
requests did not use Codex's effective outbound proxy policy.

## What changed

- Thread the configured HTTP client factory into curated plugin sync.
- Route GitHub API, zipball, backup metadata, and returned download URLs
  through the route-aware client when system proxy support is enabled.
- Preserve the existing default HTTP client behavior, including its custom CA
  fallback, when system proxy support is disabled.
- Apply the standard Codex headers to startup-sync HTTP requests.

## Testing

Add coverage that records route selection for repository, archive, metadata,
and backend-supplied download URLs, and verifies standard headers are sent.

GitOrigin-RevId: e1ea13bdab58a84c9948a2c8b82a5ec5c964ea99
2026-07-21 09:46:00 +00:00
zsol-openai
cc875d61ce Mirror Rust release artifacts to Cloudflare R2 (#34505)
## What changed

- Add a reusable workflow that runs after the GitHub Release and DotSlash publishing jobs and mirrors each release asset to a versioned R2 prefix.
- Validate GitHub asset sizes and SHA-256 digests before upload, publish objects without overwriting existing files, and verify their remote size, digest metadata, and CRC64 checksum.
- Generate `release.json` with installer-facing asset URLs and digests, then publish and verify it alongside the release assets.
- Allow an in-progress Rust release workflow to finish instead of cancelling it when another run starts.

GitOrigin-RevId: e6717cd27914994accced6e2c5df696f0e9a558e
2026-07-21 09:41:23 +00:00
jif
4f1992732c Preserve custom arg0 for sandboxed exec-server processes (#34497)
## Why

Sandbox wrappers replaced the process launch command and did not carry an
`ExecParams.arg0` override through to the inner process.

## What changed

- Route sandboxed Unix launches with a custom `arg0` through a helper mode that
  re-execs the requested program with the override.
- Expose the helper executable to the filesystem sandbox and dispatch its mode
  from Codex and exec-server test binaries.

## Testing

Add coverage for the prepared sandbox command and an end-to-end remote process
that verifies both the custom `arg0` and filesystem restrictions.

GitOrigin-RevId: c9f8eef3906d184e670184c2eeed250d5895a9ca
2026-07-21 08:59:41 +00:00
Michael Bolin
99eb575649 Honor system proxy settings in the daemon updater (#34495)
## Why

The PID-managed daemon updater downloaded the standalone installer directly,
bypassing Codex's configured outbound proxy policy.

## What changed

- Build the updater's HTTP client from the effective Codex configuration so
  `features.respect_system_proxy` also applies to installer downloads.
- Use the route-aware client pool for the installer request.
- Warn and fall back to the default `reqwest` proxy behavior when configuration
  cannot be loaded, allowing updates to continue.

## Testing

Added tests for proxy-policy selection, configuration-load fallback, exact
installer URL usage, byte preservation, and non-success HTTP responses.

GitOrigin-RevId: 559668eb40314d43afa6512da66e59e32cc1b93c
2026-07-21 08:50:21 +00:00
Michael Bolin
0e15c31d91 Route cloud environment discovery through the HTTP client pool (#34491)
## What changed

- Build a route-aware API client from the cloud backend's configured HTTP
  factory and reuse it for environment listing and autodetection.
- Replace direct `reqwest` environment requests with a small injectable HTTP
  boundary while preserving status, content-type, body, and header handling.
- Centralize asynchronous environment-list loading around the initialized
  backend context.

## Testing

- Add coverage for production header forwarding and response decoding.
- Verify repository-specific lookup, global fallback, endpoint selection,
  deduplication, and merged environment metadata with a fake HTTP client.

GitOrigin-RevId: 2e6812015ec3eb01773184541a1fad135ed53edb
2026-07-21 08:36:40 +00:00
Michael Bolin
dc21b46aea Route backend requests through the HTTP client factory (#34490)
## Why

Backend-backed features need to use the same outbound routing configuration as the rest of Codex.

## What changed

- Build the backend client on a route-aware client pool supplied by `HttpClientFactory`.
- Pass the configured factory through app-server account requests, cloud config loading, cloud tasks, and memory rate-limit checks.
- Preserve task query encoding, authentication headers, JSON request bodies, and ChatGPT cookie handling during the migration.

## Testing

- Add backend-client tests for proxy-policy propagation, task query encoding, bearer authentication, and JSON request bodies.

GitOrigin-RevId: c17d162e0dce9cec758df7cdeecf982207c6512b
2026-07-21 08:28:51 +00:00
Michael Bolin
d5998e7452 Expand route-aware proxy redirect coverage (#34483)
## What changed

- Add end-to-end coverage that exact-URL system proxy decisions select the expected route, including when a redirect switches routes.
- Verify redirects strip credential headers across origins while retaining them for the same origin and route.
- Check that redirect chains emit only the final request outcome, omit sensitive redirect details from logs, and honor disabled request logging.
- Share local HTTP listener helpers across the outbound proxy tests.

GitOrigin-RevId: afd1640e1910442d71fa1dc77b20b4fb1a6f1b6a
2026-07-21 08:00:50 +00:00
Michael Bolin
b8c2d29cc2 Add route-aware redirect test coverage (#34481)
## What changed

- Cover redirect method and body handling, `Referer` behavior, and credential
  stripping across origins.
- Exercise request deadlines across route selection and redirect hops, along
  with redirect limits and unsupported schemes.
- Verify that disabling pool request logging does not expose request or
  response data.

GitOrigin-RevId: a683956c468b45304d0bdc25081f5f4e03836ccd
2026-07-21 07:49:06 +00:00
Michael Bolin
841e47b8fb Re-resolve system proxy routes across redirects (#34479)
## Why

Route-aware clients select a direct or proxy route from the complete request
URL. Letting `reqwest` follow redirects internally reuses the client chosen for
the original URL, so the redirect destination cannot receive its own PAC or
system proxy decision.

## What changed

- Follow redirects through `RouteAwareClientPool` when respecting the system
  proxy, resolving and caching a route for every hop.
- Preserve standard redirect method and body behavior, enforce one timeout
  across the request chain, and cap redirects at 10 hops.
- Strip origin-sensitive credentials and stale proxy authorization when the
  destination or selected route changes, and apply safe `Referer` handling.
- Log one final request outcome instead of intermediate redirect responses.

## Testing

Added an integration test covering a redirect from a direct route to a proxy
route, credential handling, and final-outcome logging.

GitOrigin-RevId: e5cb2cc962e99d33df61ef649465e956b92279bb
2026-07-21 07:18:18 +00:00
viyatb-oai
c04452a240 Honor CARGO_HTTP_CAINFO in managed proxy environments (#34478)
## What changed

Add `CARGO_HTTP_CAINFO` to the curated custom CA environment variables so
Cargo inherits the managed MITM trust bundle. Preserve any startup Cargo CA
bundle in the generated trust bundle alongside the other supported overrides.

GitOrigin-RevId: 207847aa556d3a4f667ddb9e52d99e87ef984cae
2026-07-21 07:12:28 +00:00
Michael Bolin
9e5625d9cf Separate HTTP execution from request logging (#34476)
## What changed

- Add an execution path that injects trace headers and sends a request without
  logging its result.
- Extract response and error logging into reusable helpers while preserving the
  existing behavior of `HttpClient::execute`.

GitOrigin-RevId: 3feebe3da041dd08f5033dd319233d8afe9054ec
2026-07-21 07:08:04 +00:00
Dylan Hurd
1836ae0612 Preserve thread settings for goal-first and forked threads (#34469)
## Why

Goal-first and forked threads could create rollouts without recording their
effective thread settings. Resuming those threads after a restart could then
use current configuration instead of the settings selected when the thread was
created.

## What changed

- Persist a `thread_settings_applied` item when a goal first materializes a
  rollout, including a follow-up snapshot if settings changed concurrently.
- Append each fork's effective settings after its copied history so they take
  precedence over inherited settings during resume.
- Centralize conversion from `ThreadConfigSnapshot` to
  `ThreadSettingsSnapshot`.

## Testing

Added coverage that restarts the app server and verifies goal-first and forked
threads retain their respective `approvals_reviewer` settings.

GitOrigin-RevId: 6cb9aaae73bbe9ca432831cff7e826f95ffd6d01
2026-07-21 05:19:49 +00:00
Michael Bolin
9970cd706f Support alpha hotfix release versions (#34463)
## What changed

- Map Python `aN.postM` versions to Codex `-alpha.N.M` release tags through shared release-version helpers.
- Accept alpha hotfix versions in Python runtime workflows, Rust release validation, npm publishing, and the shell and PowerShell installers.

## Testing

- Cover version conversion, workflow output, runtime setup, artifact staging, and installer handling for alpha hotfix releases.

GitOrigin-RevId: b95edb56f7c93b435a8050c10f0202dc117e6669
2026-07-21 03:59:38 +00:00
charlesgong-openai
a30aee8d90 Attribute external agent imports by provider (#34451)
## What changed

- Add an optional opaque `providerId` to `externalAgentConfig/import` for analytics attribution, independently of the `migrationSource` selector.
- Include the provider ID in completed-import and import-failure analytics events.
- Have TUI imports identify their selected migration source as the provider.

## Testing

- Cover provider attribution in app-server import completion and failure tests and analytics serialization tests.

GitOrigin-RevId: 0ee7313a43652e5305939c526bf6b903a79334ad
2026-07-21 02:59:22 +00:00
charlesgong-openai
3bc49e1721 Make external session detection limits configurable (#34449)
## What changed

- Add `maxSessionAgeDays` and `maxSessions` to the external-agent config detection request.
- Apply the requested limits when discovering sessions from supported migration sources.
- Preserve the existing defaults of a 30-day maximum age and 50 sessions when either option is omitted.

GitOrigin-RevId: 46376e94b64f1f61d8776e34d82cdd2cdeb36ca0
2026-07-21 02:55:11 +00:00
Michael Bolin
9078e32371 Add a route-aware HTTP client pool (#34447)
## Why

PAC and system-proxy resolution can select a different outbound route for each
request URL. Request creation and route selection must use the same URL while
still allowing transport clients to be reused.

## What changed

- Add `RouteAwareClientPool` and a request builder that resolve the outbound
  proxy route when sending each request.
- Reuse HTTP clients by resolved route, with a bounded cache of 16 routes.
- Preserve request tracing, optional diagnostic logging, custom CA settings,
  Cloudflare cookies, and default transport redirect behavior.
- Export route-aware response and error types, including status, timeout, and
  connection-error helpers.

## Testing

Add tests for exact URL routing, client reuse and eviction, default redirects,
and redaction of URL secrets from debug output.

GitOrigin-RevId: a1688b64305a0bb276c371df63a039ccbe821b76
2026-07-21 02:37:23 +00:00
pakrym-oai
99efeef650 Add buffered code-mode exec yields (#34441)
## What changed

- Add the experimental `code_mode_buffered_exec` feature.
- When enabled, default code-mode `exec` calls without an explicit
  `yield_time_ms` to 30 seconds instead of 10 seconds.
- Report the effective default in the model-visible `exec` tool description.

## Testing

- Verify that the generated tool description advertises the 30-second default
  when the feature is enabled.

GitOrigin-RevId: 0eea4d0105137f09050ce31aad18c25c79df6b2a
2026-07-21 02:07:13 +00:00
Adam Perry @ OpenAI
c0cd337766 Increase the patch approval test timeout (#34438)
## Why

Patch approval events can take longer than the default test event timeout.

## What changed

Wait up to 15 seconds for a patch approval request or turn completion in the
approval test helper, while preserving the existing event checks and assertions.

GitOrigin-RevId: 73a50538482b5a88ccf0be07f8fad21000e54699
2026-07-21 01:16:03 +00:00
viyatb-oai
88fac6fe10 Honor managed permission profiles in network proxy resolution (#34436)
## Why

Permission profiles defined by `requirements.toml` can be selected as active,
but their network configuration was not included when resolving the network
proxy specification for that selection.

## What changed

Merge managed permission profiles from `requirements.toml` with configured
profiles before looking up the active profile's network proxy settings.

## Testing

- Verify config loading retains the proxy settings of an active managed
  profile.
- Verify `turn/start` accepts a managed profile with network settings.

GitOrigin-RevId: 3374f82a8fb0ce8f338fa2cea77c28ea2eb89636
2026-07-21 01:09:37 +00:00
Michael Bolin
c9ef7eff00 Resolve outbound proxy routes explicitly (#34435)
## Why

System proxy discovery can block, and delegating fallback to each transport can repeat discovery or apply inconsistent environment proxy behavior.

## What changed

- Resolve unavailable system proxy decisions to an explicit environment proxy or direct route, including `NO_PROXY` settings and WebSocket-specific fallbacks.
- Add asynchronous system proxy resolution that uses cached decisions first and serializes blocking platform lookups on Windows and macOS.
- Preserve `NO_PROXY` handling for WebSocket connections, including HTTP and HTTPS proxies, and hash proxy cache keys on every platform.

## Testing

- Add coverage for explicit environment fallback, cached asynchronous resolution, and proxied or bypassed WebSocket connections.

GitOrigin-RevId: 3b7cf170dcfe639eec53c3c1514f92bfcf13e7e9
2026-07-21 00:33:04 +00:00
rhan-oai
2be7d3bcd9 Support catalog messages for non-request approval policies (#34434)
## What changed

- Add model-catalog approval message variants for `never` and `unless_trusted`.
- Select the catalog message that matches the active approval policy, while retaining the existing built-in text when that variant is absent.
- Treat an explicitly empty variant as an instruction to suppress the built-in approval text, consistent with `on_request` messages.

## Testing

- Cover variant selection, fallback and empty-message behavior, catalog deserialization, and the initial permissions message sent to the model.

GitOrigin-RevId: a0f8d41a08645f39b80093be53f200eeee18ca25
2026-07-21 00:22:31 +00:00
Charlie Marsh
fd3c1dc13d Optimize remote compaction history handling (#34431)
## Why

Remote compaction can process large histories. Repeatedly estimating and replacing the full history, and cloning it when tracing is disabled, adds avoidable CPU and memory overhead.

## What changed

- Estimate each history item's token count once, update the total as trailing tool outputs are rewritten, and replace history only after all rewrites are selected.
- Preserve unclamped token totals while calculating removed tokens so saturated estimates do not hide overflow.
- Snapshot compaction input history only when rollout tracing is enabled.
- Reuse the v2 request input instead of cloning it before adding the compaction trigger.

## Testing

- Cover enabled and disabled compaction trace contexts through `is_enabled()` assertions.

GitOrigin-RevId: 8de9c9704ba29532fba05430eb204bbae2e8bf83
2026-07-20 23:30:30 +00:00
felixxia-oai
56c11cf658 Move shared skill models into codex-skills (#34429)
## What changed

- Define and export skill metadata, policy, dependency, interface, and configuration rule types from `codex-skills`.
- Update core, plugin, and extension consumers to use the shared models while retaining compatibility re-exports from `codex-core-skills`.
- Share product-restriction handling between host and environment skill metadata.

## Testing

- Add unit coverage for default and explicit implicit-invocation and product policies.

GitOrigin-RevId: 9093469f8fff8e2d902dc9781235f64709827a87
2026-07-20 23:22:48 +00:00
iceweasel-oai
35c2278dd5 Support Windows sandboxing in the exec server (#34423)
## Why

Sandboxed process launch through the exec server was unsupported on Windows.

## What changed

- Add a shared native process launcher that selects the Windows sandbox session backend when required and otherwise launches PTY or pipe-based processes.
- Pass Windows permission, workspace-root, proxy, filesystem-override, and desktop settings through exec-server process preparation.
- Preserve piped stdin and inherited file descriptors across the shared launch path.

## Testing

- Verify that a remote Windows sandbox process accepts stdin while blocking a write under a read-only policy.
- Enable workspace-root sandbox tests on native Windows while continuing to skip environments that cannot emulate Windows sandbox semantics.

GitOrigin-RevId: 6719ccbe87ad0d5a57af56503e3f23f894c60a71
2026-07-20 22:35:14 +00:00
Matthew Zeng
60272096bc Enrich app/read connector metadata (#34417)
## What changed

- Add `iconUrlDark`, `distributionChannel`, `installUrl`, and
  `pluginDisplayNames` to the experimental `app/read` connector metadata.
- Populate plugin display names from enabled plugins without starting their MCP
  servers.
- Accept both dark-icon field spellings from the batch API and keep the new
  upstream fields optional for compatibility with older responses.

## Testing

- Cover the serialized response fields, legacy batch responses, and plugin
  display-name lookup without MCP startup.

GitOrigin-RevId: 68601a104de839c0f4f4621d33b0e4d08ad88c64
2026-07-20 22:06:50 +00:00
Abhinav
cf821e8ec8 Show completed hook warnings in TUI headers (#34416)
## What changed

- Render the first line of a completed hook warning in the hook header using
  `says:`, with any remaining lines indented below it.
- Keep the existing hook header when no warning is present and avoid rendering
  warning entries a second time in the output body.
- Update hook event snapshots and the multiline warning test for the new layout.

GitOrigin-RevId: 291b556daf3b6fb64a99b090a6df1a222a18a736
2026-07-20 21:41:17 +00:00
jif
687f05cb94 Remove CSV-backed agent jobs (#34413)
## What changed

- Remove the `spawn_agents_on_csv` and `report_agent_job_result` tools and their agent-job runtime and state models.
- Drop the legacy `agent_jobs` and `agent_job_items` tables during state database migration.
- Keep `features.enable_fanout` and `agents.job_max_runtime_seconds` accepted as no-op compatibility settings while omitting them from the generated configuration schema.

## Testing

- Verify upgrades remove both legacy agent-job tables.
- Verify the removed feature and configuration keys still parse without taking effect.

GitOrigin-RevId: 8cc3337da78c67162229f02f40a747f503542646
2026-07-20 21:00:17 +00:00
Adam Perry @ OpenAI
81e89fa5af Require absolute paths for test SQLite configuration (#34411)
## Why

`SqliteConfig` stores its home as an `AbsolutePathBuf`, but its test constructor
previously accepted a `PathBuf` and checked the absolute-path invariant at
runtime.

## What changed

- Make `SqliteConfig::new_for_testing` accept an `AbsolutePathBuf` directly,
  removing its fallible conversion and `expect`.
- Update SQLite test setup to convert temporary directory paths with
  `PathExt::abs` at each call site.

GitOrigin-RevId: 93585b9aea805e2449b3465ac20eeb39417ed555
2026-07-20 20:54:08 +00:00
viyatb-oai
44481a1c45 Limit the Linux /proc preflight filesystem view (#34409)
## What changed

- Run the bubblewrap `/proc` mount probe with the minimal read-only filesystem policy instead of the command's filesystem policy and working directory.
- Preserve the requested network namespace mode during the probe.
- Add coverage that the probe mounts a temporary root and `/proc` without binding the full filesystem.

GitOrigin-RevId: e3bc4352f510980aeebe81dedf3f9211947982ed
2026-07-20 20:50:02 +00:00
stevenlee-oai
19940967bd Support threadless MCP connections without event channels (#34408)
## What changed

- Make the MCP connection manager's event sender optional.
- Skip startup notifications when a caller has no session event stream.
- Decline interactive MCP elicitations in that mode while allowing the
  underlying operation to continue.
- Update threadless resource reads, status snapshots, and connector discovery
  to use the channel-free path.

## Testing

- Extend the app-server MCP resource test to verify that a threadless resource
  read declines an elicitation and still returns the resource contents.

GitOrigin-RevId: 65fea152adbc02a78e09a40cae4134b6dccffd34
2026-07-20 20:43:36 +00:00
Owen Lin
b7e39aa316 Resolve paginated rollout lineages (#34407)
## What changed

- Add a shared local thread-store resolver that follows `history_base` links into ordered, bounded rollout segments, including archived ancestors.
- Support resolving a lineage at an explicit `HistoryPosition`.
- Reject malformed lineages with cycles, missing or mismatched source rollouts, non-paginated sources, or invalid cutoff bounds.

## Testing

- Add unit coverage for nested and archived lineages, explicit history positions, cycles, missing sources, and out-of-bounds offsets.

GitOrigin-RevId: a9063ad87e81d9865bd17fc588ea5d8e9ac74c0a
2026-07-20 20:33:51 +00:00
Charlie Marsh
ec3140db12 Update tests for history and hook API changes (#34403)
## What changed

- Assert truncated audio history through `ContextManager::raw_items()`.
- Initialize `additional_context_limit` in the quoted Windows hook command test.

GitOrigin-RevId: 43c19804e558b7a11fc17590506ec6ec7f3a9897
2026-07-20 20:06:58 +00:00
Dylan Hurd
e52c35b000 Propagate approval rejection reasons (#34400)
## What changed

- Change `ReviewDecision::Denied` to carry a rejection string and update the generated protocol schemas.
- Preserve specific rejection reasons through command, patch, network, MCP, delegated, and automatic approval flows so tool results can return them to the model.
- Distinguish invalid approval responses from user declines and truncate oversized rejection messages before adding them to model context.

## Testing

- Add coverage for denial serialization, invalid app-server approval responses, dropped automatic reviews, network rejection propagation, and rejection-message truncation.

GitOrigin-RevId: d48a55643aa03c7ecfa08a8e4b669913eec5464a
2026-07-20 19:23:21 +00:00
Andrei Eternal
8c41ed33ce Run compact session-start hooks before turn continuation (#34396)
## Why

Mid-turn auto-compaction queued `SessionStart` hooks but continued sampling
before running them. This delayed hook-provided context and ignored requests to
stop the continuation.

## What changed

Drain pending session-start hooks immediately after successful mid-turn
auto-compaction. End the turn when a hook requests a stop; otherwise include
its additional context in the next sampling request.

## Testing

Added coverage for repeated compactions in one turn, context delivery without
leaking hooks into the next user turn, and stop requests that block sampling.

GitOrigin-RevId: c57708a792fb47d98d95c38d7d91bcd9f235be84
2026-07-20 19:08:58 +00:00
Andrei Eternal
e4836f998d Add configurable hook context spill limits (#34393)
## What changed

- Add `additionalContextLimit` to command hook configuration for events that can emit `additionalContext`.
- Apply the limit independently to each hook's context before it is sent to the model. Unset values retain the 2,500-token default, while `0` disables spilling for that hook.
- Expose configured limits through app-server hook and requirements responses, and show them in the TUI hooks browser.

## Testing

- Cover JSON and TOML parsing, discovery and hashing, per-hook spilling behavior, app-server responses, and TUI rendering.

GitOrigin-RevId: 55ddc2dbbdf9067dceee3e1968c03617bbf6bcea
2026-07-20 18:46:02 +00:00
Felipe Coury
bd92b056dd Ignore inherited ACEs when refreshing Windows write roots (#34392)
## Why

An inherited `FILE_DELETE_CHILD` grant can make a write root look stale, but
`SET_ACCESS` cannot replace an ACE inherited from an ancestor. Treating that
grant as explicit causes unnecessary ACL refresh attempts that cannot converge.

## What changed

- Add explicit-ACE filtering to the Windows DACL permission checks.
- Refresh a write root only when `FILE_DELETE_CHILD` is present in an explicit
  allow ACE, while retaining effective-permission checks for required rights.
- Ignore inherited stale rights when deciding whether `SET_ACCESS` must repair
  an allow ACE.

## Testing

Add a Windows regression test covering a write root that inherits
`FILE_DELETE_CHILD`, verifying that repeated refresh checks leave its explicit
write ACE unchanged.

GitOrigin-RevId: d0df9429efcf299da3ff3c1bce92942684803293
2026-07-20 18:28:02 +00:00
Charlie Marsh
45ac251e17 Use copy-on-write storage for history snapshots (#34390)
## Why

Cloning a `ContextManager` deep-copies every `ResponseItem`, even when callers only need a read-only history snapshot.

## What changed

- Store history items in an `Arc<Vec<ResponseItem>>` so cloned snapshots share their items until one is mutated.
- Reuse an owned vector when consuming an unshared snapshot and clone it only when other snapshots still reference it.
- Estimate session token counts from a snapshot after releasing the session-state lock.

## Testing

Added a regression test that verifies cloned histories share their backing items before mutation and diverge without affecting each other afterward.

GitOrigin-RevId: 24605888209ae9ff78cadb04d9c36463f7e2dbe0
2026-07-20 18:03:12 +00:00
Alex Daley
6bf4845b60 Route Codex Apps MCP through plugin service (#34389)
## What changed

- Point the default Codex Apps MCP server at `ps/mcp` instead of the legacy Apps endpoint for both `backend-api` and `api/codex` base URLs.
- Use the same server configuration for Codex Apps and the hosted plugin runtime.
- Update MCP integration tests and test-server routing to expect the plugin-service path.

GitOrigin-RevId: 939f20dcff67ba6f79c11b328bfc624b25e3aac2
2026-07-20 17:55:58 +00:00
Dylan Hurd
5a4f5ee64c Refresh bundled model metadata (#34387)
## What changed

- Add personality instruction variables for the GPT-5.6 model variants.
- Add the GPT-5.5 availability notice.
- Remove the `auto_review` and `permissions` message fields and the legacy `supports_reasoning_summary_parameter` flag from the bundled catalog.

GitOrigin-RevId: 426b0735a78232d2f658e0124db7c45889d08286
2026-07-20 17:47:49 +00:00
Owen Lin
2793c826e8 Enable memories for paginated threads (#34386)
## Why

Paginated threads keep metadata updates in SQLite, while their rollout retains the initial `memory_mode`. Reconciliation could therefore overwrite the current setting with a stale value, and memory processing excluded these threads entirely.

## What changed

- Include paginated threads in stage 1 memory job selection and global memory output lookup.
- Preserve the SQLite `memory_mode` when reconciling or backfilling an existing paginated thread, while continuing to seed missing rows and restore legacy threads from rollouts.
- Omit `memory_mode` alongside Git metadata when flushing resumed paginated history.

## Testing

Added coverage for preserving disabled memory mode during reconciliation and backfill, selecting eligible paginated threads, and omitting initial metadata on paginated resume.

GitOrigin-RevId: 2a6e16068e69680728757fbec27aeefae45b8110
2026-07-20 17:41:33 +00:00
nhamidi-oai
6f785632b0 Preserve audio across history and tool outputs (#34385)
## Why

Audio attachments could be dropped from tool outputs and reconstructed thread history, while inline base64 payload size could overstate their model context cost.

## What changed

- Preserve remote and local audio attachments in legacy user-message events and thread history.
- Keep audio from function and custom tool outputs when the model supports it and the output fits the truncation budget; otherwise replace it with an omission marker.
- Estimate inline audio cost from its duration, with a serialized-size fallback for malformed or unsupported data URLs, so compaction and truncation use model-visible cost instead of raw base64 size.
- Replace audio in messages and tool outputs with an explanatory placeholder for models without audio input support.

## Testing

Add coverage for history round trips, dynamic tool responses, modality filtering, duration-based context estimates, output-budget truncation, and remote compaction.

GitOrigin-RevId: 5ed4628850a668f8383b7cd73db71b144cc02cd1
2026-07-20 17:36:44 +00:00
Michael Bolin
692a0fb7e5 Update packaged ripgrep to 15.2.0 (#34384)
## What changed

- Point the packaged `rg` manifest at ripgrep 15.2.0 archives for all
  supported macOS, Linux, and Windows targets.
- Update each archive's size, SHA-256 digest, and executable path.

GitOrigin-RevId: 6dcfa4fe40597a7591b8413e330d27e6b0b86627
2026-07-20 17:32:25 +00:00
jif
b00c9b2e16 Mark multi-agent v2 as stable (#34383)
## What changed

- Classify `multi_agent_v2` as stable while keeping it disabled by default.
- Exclude structured `multi_agent_v2` configuration from under-development feature warnings.

## Testing

- Update the warning-event test to verify that only the remaining under-development feature is reported.

GitOrigin-RevId: 12cb661dde9bc7b5aeae2f83476cb5ff75e0c959
2026-07-20 17:27:23 +00:00
Owen Lin
19b2273d8a Keep paginated thread Git metadata in SQLite (#34382)
## Why

Paginated rollouts contain only the initial Git metadata tuple. Reusing that
tuple during later reads, reconciliation, or resume can overwrite newer SQLite
values and undo explicit field clears.

## What changed

- Treat SQLite as authoritative for Git metadata once a thread is paginated.
- Apply paginated Git metadata patches directly to SQLite without appending
  compatibility metadata to the rollout.
- Preserve explicit null values when reading by rollout path or reconciling the
  initial session metadata, and ignore the initial Git tuple during resume.

## Testing

Added coverage for updating and clearing paginated Git metadata, preserving the
result through reconciliation and rollout-path reads, and avoiding stale Git
metadata updates on resume.

GitOrigin-RevId: 4d3e68cb24965b93d337d923092a98bac9b352b5
2026-07-20 17:23:18 +00:00
Charlie Marsh
6b9a5592a6 Avoid cloning Responses WebSocket payloads (#34381)
## Why

Building a Responses WebSocket request copied the model, instructions, input
history, tools, and other request settings into a second payload before
serialization.

## What changed

- Make `ResponseCreateWsRequest` borrow shared fields from
  `ResponsesApiRequest`.
- Keep only WebSocket-specific fields owned, and allocate a separate input
  vector only for incremental continuations.
- Restore response item IDs after preparing a full request so the request
  retained for continuation matching keeps its original state.

## Testing

Update the serialization test to verify that the borrowed WebSocket request
produces the same wire payload as the Responses API request plus its
WebSocket-specific fields.

GitOrigin-RevId: b63d746b7f5164b5204ab95b057c914a4aeb71e1
2026-07-20 17:18:25 +00:00
rka-oai
8431dc590a Stop retrying turns with invalid tool images (#34380)
## What changed

Remove the fallback that replaced image content in the latest tool output with
`Invalid image` and retried the model request. Invalid-image responses now use
the existing bad-request error path without modifying conversation history.

GitOrigin-RevId: f4ea782f16c5451feb261694caa73b77f24c3e4e
2026-07-20 16:57:03 +00:00