Skip to content

[WRONG BRANCH] Promote dev to preview: Wave 5 campaign (107 commits) - #1962

Merged
lidge-jun merged 107 commits into
previewfrom
codex/promote-preview-w5
Aug 18, 2026
Merged

[WRONG BRANCH] Promote dev to preview: Wave 5 campaign (107 commits)#1962
lidge-jun merged 107 commits into
previewfrom
codex/promote-preview-w5

Conversation

@lidge-jun

@lidge-jun lidge-jun commented Aug 18, 2026

Copy link
Copy Markdown
Owner

Summary

Promotion of the Wave 5 campaign from dev. 107 commits.

What landed, by wave:

Wave Merged
5A #1739 (via #1921), #1923, #1925, #1929
5B #1884, #1892, #1902
5C #1900, #1895 (via #1951), #1953
5D #1897, #1891, #1955, #1960, #1961

Issues closed: #1894, #1843, #1899.

A few of these are worth naming because they were not in the original plan — they came out of
adversarial review of the plan itself:

Verification

On dev at 87f7f970b:

  • bun test --isolate tests12807 pass, 10 skip, 0 fail, 159387 expect() calls across 826 files (462s).
  • bun run typecheck — passed.
  • bun run privacy:scan — passed.

Still open, deliberately

Checklist

  • Tests added or updated
  • Docs updated
  • No credentials, request bodies, or account identifiers logged
  • Promotion PR (maintainer-controlled)

Summary by CodeRabbit

  • New Features

    • Added live Antigravity model discovery with improved tier and effort handling.
    • Added optional control over direct Gemini Flash model renaming.
    • Added Cursor connectivity checks with model counts and clearer errors.
    • Added DeepSeek V4 compatibility for replayed tool-call conversations.
    • Improved Windows process discovery and Codex tool guidance.
    • Improved replay persistence and endpoint isolation across restarts.
  • Bug Fixes

    • Improved handling of truncated Cursor responses and tool arguments.
    • Corrected provider URL construction and nested function-tool parsing.
    • Preserved requested reasoning effort levels across supported adapters.
  • Documentation

    • Updated adapter and provider configuration documentation in multiple languages.

chilung-cgu and others added 30 commits August 17, 2026 08:44
Keep the existing -tiered mapping by default while allowing AI Studio providers that still serve bare Gemini Flash ids to opt out. Cover both Flash generations and document the provider setting.
…-out

- identifyRoutedModel now names parsed.modelId so a -tiered wire rename never leaks into the system prompt identity (CodeRabbit finding)
- document that directGeminiWireRenames affects only AI Studio direct requests; Vertex and Cloud Code Assist are unchanged
- add adapter tests for explicit true and Cloud Code Assist opt-out
…ctor

Phase A0 of the FastWire umbrella (#1886): characterization
suites only, zero production changes. Locks the three-state fastMode contract,
the unclassified passthrough matrix, exact-model foreign-tier forwarding, the
mixed requestedServiceTier logging semantics, routing/fingerprint projections,
catalog tier-field byte goldens, and two known bugs (native chat ignores
exact-model false; chat-to-responses conversion drops service_tier) as current
behavior. Full suite at this commit: 12746 pass / 10 skip / 0 fail.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…udge

Routed providers were told the valid names were exactly the flat top-level catalog. In Codex code mode, deferred helpers such as tools.codex_app__list_threads stay callable inside exec even when they are omitted from the listed names and from exec description. Discover them from the isolate global ALL_TOOLS, not tools.ALL_TOOLS.
…tch callable

CodeRabbit on #1895: use the transformed exec wire name in the shared catalog nudge, and do not forbid apply_patch at the top level when that tool is separately advertised in code mode.
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Count createPlanRequestQuery text as assistant output before clean EOF,
reject non-loopback http discovery URLs before sending the Bearer token,
and return the live model count as structured data on the Cursor probe.
CodeRabbit asked to throw on incomplete tools at Connect EOF. That would
hide the existing fail-closed error event as a generic transport failure.
lidge-jun and others added 16 commits August 18, 2026 11:07
Wave 5D was smaller than planned. #1897 had already merged as aca3c02 and
#1836 was already closed, so half the wave was resolved before the phase ran.

#1891 I verified rather than took on trust: clean merge onto dev, 75 pass / 0
fail across the three fingerprint suites, typecheck clean. Its description
carries a decompiled token sequence and a live round trip, which is the right
evidence for a fingerprint change because the failure mode is silent upstream
rejection rather than a failing test. It is held only by its own unticked
readiness checklist.

#1889 is the campaign's second auth-surface block after #1888. It touches
src/oauth/, MAINTAINERS.md requires explicit security review there, and the
maintainer-sponsored label is the record that the review happened - so applying
it to unblock a merge would make the record false rather than skip a step.
….5.5 decompilation

- Align token sequence in antigravityUserAgent to match decompiled Go Language Server setHeaders (0x1018fbe00): os_type -> arch -> aidev_client -> auth_method=oauth.
- Result: antigravity/ide/2.5.5 (os_type=windows; arch=amd64; aidev_client; auth_method=oauth).
- Update unit and wire tests to assert exact decompiled token sequence.
…erride regression tests

- Use antigravityUserAgent() for ANTIGRAVITY_REQUEST_UA to ensure trimmed override handling.
- Add focused regression tests for GOOGLE_ANTIGRAVITY_USER_AGENT and PI_AI_ANTIGRAVITY_USER_AGENT (trimming, precedence, whitespace fallback).
… env var

- Allow optional authMethod parameter on antigravityUserAgent (defaults to oauth).
- Drop undocumented PI_AI_ANTIGRAVITY_USER_AGENT override to keep changes minimal.
Onboarding was filling metadata.ide_version with antigravityUserAgent(), which
returns the entire header - antigravity/ide/2.5.5 (aidev_client; os_type=...;
arch=...) - where the real client sends 2.5.5.

Nothing failed, and that is the point. The request still succeeds; it just does
not look like Antigravity. A fingerprint is only worth having if it matches, and
this one had a parenthesized UA string sitting in a version field on every
onboarding call.

ANTIGRAVITY_IDE_VERSION already existed one import away. The regression pins the
field and asserts the shape it must not have, so the next person reaching for
the UA helper here gets a failure instead of a silently wrong fingerprint.

Driven red: restoring antigravityUserAgent() fails the new test.
…ompted

Two record errors. #1889 has two distinct failing checks, not four - four was
the count of failing check runs across re-runs. And the audit's finding that
#1891 sits 62 commits behind dev is itself stale: the live head 8123680 is 0
behind, so ticking alone is now sufficient. Keeping that as a lesson rather
than deleting it, because the mechanism it named is real and would have made my
advice wrong on a different day.

The audit also asked whether anything here could be landed rather than held,
and one thing could: metadata.ide_version was set to antigravityUserAgent(),
the whole header, where the real client sends a bare version. Live on dev,
independent of both PRs, and invisible because the request still succeeds.
Fixed in #1955.

That distinction is worth stating. I hold #1889 because reviewing someone
else's auth change is the maintainer act the sponsorship label records - but a
one-line auth fix I wrote and verified myself is precisely the case where a
maintainer sponsors their own work.
Two corrections from the promotion audit.

The closed table listed #1894, #1843 and #1899 as issues. #1899 is a pull
request, so two issues closed this campaign, not three - the original phrasing
overstated the run.

And PR #1921's merge commit carries a failing hosted run. The failure is a
wall-clock assertion in request-pacing, the classic flake shape on a loaded
macOS runner, and every subsequent run on dev is green including the current
head. Not a blocker, but it landed red and the record did not say so. A campaign
record that omits the one merge that went in red is not one you can trust later.

Also supersedes the no-green-run statement: run 32090176020 on 9eb3a10 is
completed/success with every job green.
…ersion

fix(antigravity): send a bare ide_version, not the whole User-Agent
fix(antigravity): align User-Agent token order and auth_method with 2.5.5 decompilation
fix(antigravity): send a bare ide_version + Wave 5 closeout record
#1891's hold expired four minutes after I wrote it - the author rebased and
ticked all four boxes at 02:10:50Z - so it merged as 5c66ad2. Wave 5D is now
down to #1889 alone, blocked on maintainer sponsorship.

The full suite on the merged tree is 12805 pass, 10 skip, 1 fail. The failure is
the Unix shim autostart test failing with status 126, permission denied on exec,
and it is environmental rather than a regression: it reproduces solo, it fails
identically at the pre-campaign baseline 1208bd2, and all four test shards
passed in dev CI for 9eb3a10. The test writes a shim to a temp dir and
spawnSyncs it; this sandbox blocks execution from that path. Recorded rather
than skipped - the fix is an environment note, not a test change.
The autostart shim test deleted OCX_SHIM_ACTIVE_PID from the child environment
but inherited OCX_SHIM_ACTIVE_DEPTH from the parent. A developer running the
suite from a shell that was itself launched through an installed Codex shim
carries DEPTH=1, so the outer shim started at depth 1 rather than 0, the child
re-entry landed on depth 2, and the guard exited 126 with its launcher-loop
message. The shim was behaving exactly as designed; the test was starting from
a slate it believed was clean.

CI never sees this because CI has no shimmed ancestor, which is precisely what
made it look like a machine quirk.

I had recorded the cause as the sandbox blocking execution from a temp path.
That was wrong - a chmod 755 script in mktemp -d runs fine here and /var/folders
is not mounted noexec - and a reviewer traced the real mechanism. The devlog now
carries the correction, because a plausible-sounding wrong explanation in a
durable record is worse than no explanation.
fix(test): sanitize both shim recursion-guard variables
The previous fix deleted both guard variables at one spawn site. A reviewer
pointed out the class of bug survives: the nearby re-entry tests assert status
126, so an inherited depth offset leaves them passing for entirely the wrong
reason, and the next test to spawn a shim starts the cycle again.

shimChildEnv strips PID, DEPTH and PROBE_ACTIVE in one place, mirroring what
probeUnixShimInstall already does before spawning its probe. The second spawn
site at line 291 had the same gap - it deleted only the pid - so it was quietly
depth-sensitive too.

What this buys is that a green run means what it says. Before, these tests
measured whatever shim ancestry the developer's shell happened to carry, and
were green in CI only because CI has no shimmed ancestor.
test(codex): centralize shim recursion-guard sanitization
@github-actions

Copy link
Copy Markdown
Contributor

Deterministic PR hygiene checks passed.

@lidge-jun
lidge-jun merged commit a43150c into preview Aug 18, 2026
32 of 35 checks passed
@coderabbitai

coderabbitai Bot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 24784865-3982-4d2b-b2b6-946dde6d9cd5

📥 Commits

Reviewing files that changed from the base of the PR and between 506bcab and 87f7f97.

📒 Files selected for processing (64)
  • devlog/_plan/260817_wave5_execution/000_research.md
  • devlog/_plan/260817_wave5_execution/001_audit_synthesis.md
  • devlog/_plan/260817_wave5_execution/002_merge_order_corrections.md
  • devlog/_plan/260817_wave5_execution/010_1894_gemini_wire_id.md
  • devlog/_plan/260817_wave5_execution/020_1899_harden_ordering.md
  • devlog/_plan/260817_wave5_execution/030_1876_windows_discovery.md
  • devlog/_plan/260817_wave5_execution/040_thought_signature_scope.md
  • devlog/_plan/260817_wave5_execution/050_1849_1049_durability.md
  • devlog/_plan/260817_wave5_execution/060_wave5b_continuation.md
  • devlog/_plan/260817_wave5_execution/070_wave5c_cursor.md
  • devlog/_plan/260817_wave5_execution/080_wave5d_antigravity.md
  • devlog/_plan/260817_wave5_execution/090_wave6_closeout.md
  • docs-site/src/content/docs/ja/reference/adapters.md
  • docs-site/src/content/docs/ko/reference/adapters.md
  • docs-site/src/content/docs/reference/adapters.md
  • docs-site/src/content/docs/reference/configuration/providers.md
  • docs-site/src/content/docs/ru/reference/adapters.md
  • docs-site/src/content/docs/zh-cn/reference/adapters.md
  • docs-site/src/content/docs/zh-tw/guides/providers.md
  • src/adapters/client-fingerprint.ts
  • src/adapters/cline-pass-deepseek-v4-tool-replay.ts
  • src/adapters/cursor/live-models.ts
  • src/adapters/cursor/live-transport.ts
  • src/adapters/cursor/tool-definitions.ts
  • src/adapters/google-antigravity-wire.ts
  • src/adapters/google.ts
  • src/adapters/openai-responses-url.ts
  • src/adapters/registry.ts
  • src/adapters/tool-catalog-nudge.ts
  • src/codex/app-server-processes.ts
  • src/codex/catalog/provider-fetch.ts
  • src/config.ts
  • src/oauth/google-antigravity.ts
  • src/providers/antigravity-models.ts
  • src/providers/derive.ts
  • src/responses/parser.ts
  • src/responses/reasoning-replay-cache.ts
  • src/responses/thought-signature-replay.ts
  • src/router.ts
  • src/server/management/provider-routes.ts
  • src/server/responses/core.ts
  • src/types.ts
  • tests/client-fingerprint.test.ts
  • tests/cline-pass-deepseek-v4-tool-replay.test.ts
  • tests/cline-pass-provider.test.ts
  • tests/codex-app-server-processes.test.ts
  • tests/codex-catalog-writer.test.ts
  • tests/codex-shim.test.ts
  • tests/config.test.ts
  • tests/cursor-hardening.test.ts
  • tests/cursor-tool-arg-decoding.test.ts
  • tests/cursor-tool-definitions.test.ts
  • tests/fastwire-characterization-routing.test.ts
  • tests/fastwire-characterization-wire.test.ts
  • tests/gemini-37-flash-migration.test.ts
  • tests/google-adapter.test.ts
  • tests/google-antigravity-oauth.test.ts
  • tests/google-antigravity-wire.test.ts
  • tests/google-models-listing.test.ts
  • tests/google-signature-history-roundtrip.test.ts
  • tests/openai-responses-passthrough.test.ts
  • tests/provider-connection-test.test.ts
  • tests/responses-parser.test.ts
  • tests/tool-catalog-nudge.test.ts

📝 Walkthrough

Walkthrough

Changes

The pull request adds Wave 5 execution records and updates adapter behavior across Google, Antigravity, Cursor, Codex, replay persistence, tool parsing, and catalog guidance. It also adds regression tests and multilingual documentation updates.

Wave 5 execution records

Layer / File(s) Summary
Execution plans and closeout records
devlog/_plan/260817_wave5_execution/*
Adds research, audit synthesis, merge-order corrections, work plans, wave outcomes, verification results, blockers, and closeout policy records.
Google and Antigravity model routing
src/adapters/google.ts, src/providers/antigravity-models.ts, src/codex/catalog/provider-fetch.ts, src/types.ts, src/config.ts, src/oauth/google-antigravity.ts, src/adapters/client-fingerprint.ts, src/adapters/google-antigravity-wire.ts, docs-site/src/content/docs/reference/configuration/providers.md, docs-site/src/content/docs/*/reference/adapters.md, docs-site/src/content/docs/zh-tw/guides/providers.md
Adds configurable direct Gemini wire renaming, separates routed and identity model IDs, records discovered Antigravity wire mappings by base URL and cache generation, updates fingerprint metadata, and preserves requested ClinePass reasoning tiers in documentation.
Durable replay scope
src/responses/reasoning-replay-cache.ts, src/responses/thought-signature-replay.ts, src/server/responses/core.ts, src/types.ts, tests/google-signature-history-roundtrip.test.ts
Adds deterministic destination identities, includes them in replay keys, invalidates older snapshots through store versioning, and tests endpoint isolation and restart persistence.
Cursor discovery and transport behavior
src/adapters/cursor/live-models.ts, src/adapters/cursor/live-transport.ts, src/server/management/provider-routes.ts, tests/cursor-hardening.test.ts, tests/provider-connection-test.test.ts
Validates Cursor discovery URLs, adds injectable discovery fetching, reports discovered model counts, and distinguishes clean EOF after assistant output from incomplete tool-call termination.
Windows process discovery and cache states
src/codex/app-server-processes.ts, tests/codex-app-server-processes.test.ts
Adds injectable PowerShell execution and exported snapshot parsing. Top-level CIM failures now produce unknown, and unknown states use a 250 ms cache TTL.
Adapter compatibility and catalog normalization
src/adapters/cline-pass-deepseek-v4-tool-replay.ts, src/adapters/registry.ts, src/responses/parser.ts, src/providers/derive.ts, src/router.ts, src/adapters/cursor/tool-definitions.ts, src/adapters/tool-catalog-nudge.ts, tests/*
Adds DeepSeek V4 tool-replay normalization, nested function-tool parsing, shared legacy ClinePass detection, command aliases, and Codex code-mode guidance with validation coverage.
Supporting regressions
src/adapters/openai-responses-url.ts, tests/openai-responses-passthrough.test.ts, tests/codex-catalog-writer.test.ts, tests/codex-shim.test.ts, tests/fastwire-characterization-*.test.ts
Normalizes Responses URLs and expands coverage for writer ordering, shim environment cleanup, and FastWire routing and wire behavior.

Estimated code review effort: 5 (Critical) | ~120 minutes

✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/promote-preview-w5

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

⏳ DRAFT

  • wrong target branch (preview); retarget to dev.

What to do

  • Retarget this PR to dev — all contributions go to dev.

Its title has been prefixed with [WRONG BRANCH].
Automatic draft conversion failed (token cannot change draft status). Please convert this pull request to a draft manually. The required enforce-target check will keep failing until every issue above is resolved.

@github-actions github-actions Bot changed the title Promote dev to preview: Wave 5 campaign (107 commits) [WRONG BRANCH] Promote dev to preview: Wave 5 campaign (107 commits) Aug 18, 2026
@lidge-jun

Copy link
Copy Markdown
Owner Author

Disclosure that belongs on this PR and landed on the wrong one.

I opened #1958/#1959 as promotion PRs and put a detailed disclosure in their descriptions. This
PR and #1962 are the ones that actually performed the promotion — merged at 02:55:01/04, with
#1958/#1959 flipping to merged seconds later once their heads became reachable. So the
disclosure never reached the artifacts that moved the code.

A campaign PR introduced a high-severity CodeQL alert, and it is now on main.

js/polynomial-redos at src/providers/antigravity-models.ts:273
— the baseUrl.trim().replace(/\/+$/, "") in antigravityBaseUrlKey. It arrived in commit
0be660a2e via aca3c0241 from #1897, which I merged during Wave 5D.
git merge-base --is-ancestor 0be660a2e v2.24.2 returns false, so it postdates the release —
this is not inherited. git merge-base --is-ancestor 0be660a2e origin/main now returns true.

Severity in context: the input is a configured baseUrl, so exploitation needs a hostile or
careless config rather than attacker-controlled traffic. Worth fixing, not urgent. A
non-backtracking form does the same job:

const trimmed = baseUrl.trim().replace(/(?<=[^/])\/+$/, "");

Note it changes behaviour for an all-slashes input, and the same commit added a second
.replace(/\/+$/, "") on the following line that CodeQL did not flag but which has the same
shape. Details and the fuller writeup are on #1897 and in
devlog/_plan/260817_wave5_execution/090_wave6_closeout.md.

Separately: dev carries 84 open code-scanning alerts against main's 71. The rest predate
this campaign — this one does not.

@lidge-jun

Copy link
Copy Markdown
Owner Author

Disclosure that belongs in this PR body and was not there when it merged.

This promotion carried a high-severity CodeQL alert the campaign itself introduced: #87, js/polynomial-redos, at src/providers/antigravity-models.ts:273, from 0be660a2e via #1897.

It is fixed in #1966 and promoted in #1967/#1968, so preview and main no longer carry the pattern — but it shipped here first, and the PR body claimed a disclosure it did not contain.

Root cause, corrected once already: my first explanation was that merging on local tests plus tsc skipped static analysis. The real one is narrower — CodeQL never runs on dev-targeting PRs at all. It scans dev on push and main-targeting PRs, so no amount of per-PR CI waiting would have caught it. The alert was visible among 84 open ones and nobody read them.

lilinxiong pushed a commit to lilinxiong/opencodex that referenced this pull request Aug 18, 2026
…rong PRs

Dev reached preview and main through lidge-jun#1962 and lidge-jun#1963, not through the lidge-jun#1958 and
lidge-jun#1959 I opened and left for a maintainer - those flipped to merged seconds later
once their heads became reachable.

So the disclosure I spent three audit rounds getting right sat on the two PRs
that moved no code, and the two that actually promoted carried none of it. Fixed
by commenting it onto lidge-jun#1962 and lidge-jun#1963 after the fact, which is later than it
should have been.

Worth naming the failure mode rather than just the fix: I attached the warning
to the artifact I controlled rather than to the artifact that would carry the
change. js/polynomial-redos is on main now.

What I did not do and stand by: I never approved a promotion PR.
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.

10 participants