Skip to content

Commit 6c0bde4

Browse files
committed
fix: stabilize dev head after the 260818 merge train
Close the five regressions that turned dev-head CI red at aaf0469: - core.ts: scope the #1851 transient-5xx retry to the direct Google adapter. The generic openai-chat path returned to reset-only retry, so combo failover hops on the first 5xx again instead of burning three same-target attempts per hop (6 combo e2e failures, 2 sidecar-auth timeouts). - commandcode-provider.test.ts: #1800 surfaces the curated effort table; the sibling test still expected [] (its hyphenated twin was updated). - bridge-raw-reasoning-hidden.test.ts: #2007 routes visible raw reasoning through the expandable summary channel; two tests still asserted the retired content-channel shape. - codex-app-server-processes.test.ts + cli-restore-back.test.ts: #1931 intentionally refreshes the ocx-side catalog/cache during explicit sync while Codex integration is OFF; the source-inspection and message assertions now track that contract (Codex config mtime is still asserted untouched). - gui models-empty-provider test: #1991 renamed the dialog button to "Custom windows"; the test still clicked "Context windows". Plus the WP-V stabilization audit plan doc for the campaign unit.
1 parent aaf0469 commit 6c0bde4

7 files changed

Lines changed: 94 additions & 31 deletions

File tree

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# 010 — WP-V stabilization audit (post-interruption)
2+
3+
Context: prior session (thread 01a0138d) was interrupted mid-campaign by a codex
4+
runtime error; user reports "too much merged too fast" and asks for a full
5+
main..dev merge appropriateness audit + CI + lidge suite before continuing.
6+
7+
Range: origin/main (e97fb2621, v2.25.0) .. origin/dev (aaf04690e), 125 commits.
8+
A new push to dev re-opens ALL THREE verifiers (CI, lidge suite, whole-delta diff).
9+
10+
## Audit lanes (parallel, gpt-5.6-sol medium, read-only)
11+
12+
- Lane A — campaign land-* merges: #2015(1800) #2016(2007) #2017(1990)
13+
#2018(1889+1883-followup) #2020(1896) #2021(1932). Check: matrix verdict match,
14+
rebase correctness (vpr-* merge shape), tests present, no scope creep.
15+
- Lane B — campaign batch merges: 1991 1931 1912 1859 1847 1845 (merge),
16+
1935 1725 1851 (squash), 1883 (squash, workflow security). Check: matrix match,
17+
squash-vs-merge shape as prescribed, workflow security for 1883.
18+
- Lane C — pre-campaign merges on dev: 1928 1941 2005 1904 1965 1893 1949
19+
1944-1947 1998 1997 + docs 2004-2014 + b5a98d690 release-audit fixes.
20+
Check: each is a reviewed, coherent landing; docs merges are docs-only.
21+
- Lane D — whole-delta security/semantic scan: git diff origin/main..origin/dev
22+
focused on src/ high-risk surfaces, explicitly including:
23+
.github/scripts/install-copilot-cli.sh + run-copilot-inference.cjs (supply chain,
24+
#1883), src/lib/windows-service-wrappers.ts + windows-atomic-replace.ts
25+
(privileged kill/replace), src/server/management/system-routes.ts + shared.ts
26+
(management API), src/codex/auth-api.ts + plan-from-token.ts (#1998/#1932 WHAM
27+
401 gating), src/oauth/google-antigravity.ts (#1889), src/lib/redact.ts,
28+
scripts/build-release-changelog.ts (#1847), MiniMax loopback pin e9d879b34.
29+
30+
## Verifiers (PLAN-VERIFIER-REAL-01)
31+
32+
- gh run watch 32130622133 (Cross-platform CI on aaf04690e) — observes dev head; running now.
33+
- ssh lidge full suite (typecheck + bun test --isolate tests + privacy:scan) in a
34+
DEDICATED git worktree pinned at aaf04690e (~/.wpv-suite-aaf04690e). The shared
35+
~/Developer/opencodex checkout is owned by a concurrent session (split-wp1b) and
36+
was swapped mid-run — the first suite attempt (ssh session 27978) is VOID.
37+
- Failure baseline: any lidge failure is classified by bisect-attribution into
38+
e97fb2621..aaf04690e (ours) vs reproduction at 0f5ccf9aa pre-campaign tip
39+
(preexisting). No judgment-call classifications.
40+
- Local dirty worktree (#1748 delta) is stashed out of scope for WP-V; it belongs to wp6.
41+
42+
## Accept criteria
43+
44+
- Every merge group has a verdict: OK / SUSPECT(reason) / REGRESSION(evidence);
45+
coverage list is exact over all 125 commits (incl. docs #2004).
46+
- CI conclusion recorded for exact SHA aaf04690e (or successor if new pushes land).
47+
- lidge suite exit codes recorded; failures classified ours-vs-preexisting.
48+
- Any REGRESSION gets fix-forward or targeted revert in B, re-verified in C.
49+
50+
Out of scope: wp6-wp11 work (later cycles).

‎gui/tests/models-empty-provider.test.tsx‎

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -221,8 +221,8 @@ test("Models page combines final visibility, atomic actions, discovery status, a
221221
expect(container.querySelector(".badge.badge-amber")?.textContent).toContain("Discovery failed");
222222
expect(container.textContent).not.toContain("Not selected");
223223

224-
await act(async () => buttonText("Context windows").click());
225-
const contextDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Context windows"]')!;
224+
await act(async () => buttonText("Custom windows").click());
225+
const contextDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Custom windows"]')!;
226226
const contextInputs = contextDialog.querySelectorAll<HTMLInputElement>("input");
227227
expect([...contextInputs].map(input => input.value)).toEqual(["256000", "64000"]);
228228
const setValue = Object.getOwnPropertyDescriptor(
@@ -275,10 +275,10 @@ test("Models page combines final visibility, atomic actions, discovery status, a
275275
contextWindow: 350_000,
276276
modelContextWindows: { "claude-opus": 100_000, "claude-sonnet": 80_000 },
277277
});
278-
expect(container.querySelector('[role="dialog"][aria-label="Context windows"]')).toBeNull();
278+
expect(container.querySelector('[role="dialog"][aria-label="Custom windows"]')).toBeNull();
279279

280-
await act(async () => buttonText("Context windows").click());
281-
const refreshFailureDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Context windows"]')!;
280+
await act(async () => buttonText("Custom windows").click());
281+
const refreshFailureDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Custom windows"]')!;
282282
failCatalog = true;
283283
// Make an actual edit. Apply now compares against the values the modal opened with, so a
284284
// reopened-and-untouched dialog sends nothing — which would leave this case asserting the
@@ -296,15 +296,15 @@ test("Models page combines final visibility, atomic actions, discovery status, a
296296
});
297297
expect(contextBodies).toHaveLength(2);
298298
expect(contextBodies.at(-1)).toEqual({ contextWindow: 360_000 });
299-
expect(container.querySelector('[role="dialog"][aria-label="Context windows"]')).toBeNull();
299+
expect(container.querySelector('[role="dialog"][aria-label="Custom windows"]')).toBeNull();
300300
expect(container.textContent).toContain("Context windows updated");
301301
failCatalog = false;
302302

303303
// An edit that is typed and then restored is not a change — and neither is retyping the
304304
// same number in a different shape. Comparing raw text instead of parsed values would
305305
// treat "64,000" as an edit and stamp a stale number over whatever else moved.
306-
await act(async () => buttonText("Context windows").click());
307-
const revertDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Context windows"]')!;
306+
await act(async () => buttonText("Custom windows").click());
307+
const revertDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Custom windows"]')!;
308308
const revertInput = revertDialog.querySelectorAll<HTMLInputElement>("input.input")[0]!;
309309
const openingValue = revertInput.value;
310310
await act(async () => {
@@ -320,10 +320,10 @@ test("Models page combines final visibility, atomic actions, discovery status, a
320320
await new Promise(resolve => testWindow.setTimeout(resolve, 0));
321321
});
322322
expect(contextBodies).toHaveLength(2);
323-
expect(container.querySelector('[role="dialog"][aria-label="Context windows"]')).toBeNull();
323+
expect(container.querySelector('[role="dialog"][aria-label="Custom windows"]')).toBeNull();
324324

325-
await act(async () => buttonText("Context windows").click());
326-
const reformatDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Context windows"]')!;
325+
await act(async () => buttonText("Custom windows").click());
326+
const reformatDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Custom windows"]')!;
327327
const reformatInput = reformatDialog.querySelectorAll<HTMLInputElement>("input.input")[0]!;
328328
const commaFormatted = reformatInput.value.replace(/\B(?=(\d{3})+(?!\d))/g, ",");
329329
await act(async () => {
@@ -353,8 +353,8 @@ test("Models page combines final visibility, atomic actions, discovery status, a
353353
// The poll has to actually run: mutating the mock alone leaves React's `groups` on the
354354
// opening values, and then comparing drafts against LIVE state — the defect — would look
355355
// identical to comparing against the snapshot.
356-
await act(async () => buttonText("Context windows").click());
357-
const concurrentDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Context windows"]')!;
356+
await act(async () => buttonText("Custom windows").click());
357+
const concurrentDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Custom windows"]')!;
358358
providerContextWindow = 300_000;
359359
providerModelContextWindows = { ...providerModelContextWindows, "claude-opus": 96_000 };
360360
await act(async () => { poll(); await new Promise(resolve => testWindow.setTimeout(resolve, 0)); });
@@ -379,8 +379,8 @@ test("Models page combines final visibility, atomic actions, discovery status, a
379379
// `groups` instead of the opening snapshot. The cases above cannot see that swap, because
380380
// in each of them the user's value genuinely differs from both. This one does — the user
381381
// touches a field and puts it back, while the server moves underneath.
382-
await act(async () => buttonText("Context windows").click());
383-
const staleDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Context windows"]')!;
382+
await act(async () => buttonText("Custom windows").click());
383+
const staleDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Custom windows"]')!;
384384
const staleDefaultInput = staleDialog.querySelectorAll<HTMLInputElement>("input.input")[0]!;
385385
const staleOpeningDefault = staleDefaultInput.value;
386386
await act(async () => {
@@ -419,8 +419,8 @@ test("Models page combines final visibility, atomic actions, discovery status, a
419419
// anyone whose config was hand-edited before the safe-integer bound existed.
420420
providerContextWindow = 1e100;
421421
await act(async () => { poll(); await new Promise(resolve => testWindow.setTimeout(resolve, 0)); });
422-
await act(async () => buttonText("Context windows").click());
423-
const unsafeDefaultDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Context windows"]')!;
422+
await act(async () => buttonText("Custom windows").click());
423+
const unsafeDefaultDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Custom windows"]')!;
424424
await pickContextModel("claude-sonnet", unsafeDefaultDialog);
425425
const unsafeSiblingInput = unsafeDefaultDialog.querySelectorAll<HTMLInputElement>("input.input")[1]!;
426426
await act(async () => {
@@ -438,8 +438,8 @@ test("Models page combines final visibility, atomic actions, discovery status, a
438438
// `Number.isInteger(1e100)` is true, and the server rejects it. Accepting it in the form
439439
// would turn a typo into a round-trip error instead of inline feedback.
440440
const patchesBeforeUnsafe = contextBodies.length;
441-
await act(async () => buttonText("Context windows").click());
442-
const unsafeDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Context windows"]')!;
441+
await act(async () => buttonText("Custom windows").click());
442+
const unsafeDialog = container.querySelector<HTMLElement>('[role="dialog"][aria-label="Custom windows"]')!;
443443
const unsafeInput = unsafeDialog.querySelectorAll<HTMLInputElement>("input.input")[0]!;
444444
await act(async () => {
445445
setValue.call(unsafeInput, "1e100");
@@ -454,7 +454,7 @@ test("Models page combines final visibility, atomic actions, discovery status, a
454454
// Relative, not absolute: an absolute count silently re-targets whenever a case is added
455455
// above, and the property under test is "this Apply wrote nothing".
456456
expect(contextBodies).toHaveLength(patchesBeforeUnsafe);
457-
expect(container.querySelector('[role="dialog"][aria-label="Context windows"]')).not.toBeNull();
457+
expect(container.querySelector('[role="dialog"][aria-label="Custom windows"]')).not.toBeNull();
458458
// The modal staying open is not the point — the user has to be TOLD why. Without this the
459459
// test passes on a silent no-op that looks identical to a hang.
460460
expect(unsafeDialog.textContent).toContain("Context windows must be positive whole numbers");

‎src/server/responses/core.ts‎

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3669,7 +3669,12 @@ async function handleResponsesInner(
36693669
}),
36703670
});
36713671
} else {
3672-
upstreamResponse = await fetchWithTransientRetry(
3672+
// #1851 scope guard: transient-5xx retry on this generic adapter path is opt-in for
3673+
// direct Google AI Studio only (Vertex/Antigravity use fetchResponse above). Other
3674+
// adapters keep reset-only retry so combo failover still hops on the first 5xx
3675+
// instead of burning ~1.2s of same-target retries per hop.
3676+
const fetchWithRetryPolicy = route.provider.adapter === "google" ? fetchWithTransientRetry : fetchWithResetRetry;
3677+
upstreamResponse = await fetchWithRetryPolicy(
36733678
recovery => {
36743679
noteAttemptSend(logCtx.activeAttempt, inputTokenEstimate, recovery);
36753680
return fetchWithHeaderTimeout(builtInitialRequest.url, applyUpstreamRecoveryInit({
@@ -4099,7 +4104,10 @@ async function handleResponsesInner(
40994104
}),
41004105
});
41014106
}
4102-
return await fetchWithTransientRetry(
4107+
// Same #1851 scope guard as the initial send: transient-5xx retry only for direct
4108+
// Google AI Studio; every other adapter keeps reset-only semantics here.
4109+
const fetchContinuationWithRetryPolicy = route.provider.adapter === "google" ? fetchWithTransientRetry : fetchWithResetRetry;
4110+
return await fetchContinuationWithRetryPolicy(
41034111
recovery => {
41044112
noteAttemptSend(logCtx.activeAttempt, continuationEstimate, recovery ?? replayKind);
41054113
return fetchWithHeaderTimeout(

‎tests/bridge-raw-reasoning-hidden.test.ts‎

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -77,17 +77,18 @@ describe("hidden raw reasoning (hideThinkingSummary parity for reasoning_raw_del
7777
expect(fc).toMatchObject({ call_id: "call_1", name: "read_file" });
7878
});
7979

80-
test("streamed visible (flag off): current raw shape unchanged", async () => {
80+
test("streamed visible (flag off): raw reasoning rides the expandable summary channel (#2007)", async () => {
8181
const frames = await collectSse(bridgeToResponsesSSE(replay([
8282
{ type: "reasoning_raw_delta", text: "visible raw" },
8383
{ type: "done" },
8484
]), "routed/model"));
85-
expect(frames.some(f => f.event === "response.reasoning_text.delta")).toBe(true);
85+
expect(frames.some(f => f.event === "response.reasoning_summary_text.delta")).toBe(true);
86+
expect(frames.some(f => f.event === "response.reasoning_text.delta")).toBe(false);
8687
const completed = frames.find(f => f.event === "response.completed")?.data.response as Record<string, unknown>;
8788
const output = completed.output as Record<string, unknown>[];
8889
expect(output[0]).toMatchObject({
89-
type: "reasoning", summary: [],
90-
content: [{ type: "reasoning_text", text: "visible raw" }],
90+
type: "reasoning",
91+
summary: [{ type: "summary_text", text: "visible raw" }],
9192
});
9293
});
9394

@@ -117,14 +118,14 @@ describe("hidden raw reasoning (hideThinkingSummary parity for reasoning_raw_del
117118
expect(decodeReasoningEnvelope(reasoning.encrypted_content as string)?.txt).toBe("quiet");
118119
});
119120

120-
test("non-streaming visible: raw shape unchanged", () => {
121+
test("non-streaming visible: raw reasoning lands in the summary channel (#2007)", () => {
121122
const json = buildResponseJSON([
122123
{ type: "reasoning_raw_delta", text: "loud" },
123124
{ type: "done" },
124125
], "routed/model", {});
125126
const output = (json as { output: Record<string, unknown>[] }).output;
126127
expect(output.find(o => o.type === "reasoning")).toMatchObject({
127-
content: [{ type: "reasoning_text", text: "loud" }],
128+
summary: [{ type: "summary_text", text: "loud" }],
128129
});
129130
});
130131

‎tests/cli-restore-back.test.ts‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,9 @@ describe("ocx restore back", () => {
9999
CI: "1",
100100
});
101101
expect(result.status).toBe(0);
102-
expect(`${result.stdout}\n${result.stderr}`).toContain("Codex integration is OFF; sync skipped and no Codex files changed.");
102+
// #1931: explicit sync now refreshes the ocx-side catalog/cache while OFF; the
103+
// durable policy result is still "Codex config untouched" (mtime asserted below).
104+
expect(`${result.stdout}\n${result.stderr}`).toContain("Codex integration is OFF; catalog and models cache refreshed, Codex config untouched.");
103105
expect(statSync(configPath).mtimeMs).toBe(before);
104106
} finally {
105107
rmSync(codexHome, { recursive: true, force: true });

‎tests/codex-app-server-processes.test.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,8 @@ describe("CLI /api sync wiring for stale app-servers (#476)", () => {
389389
// The property under test is unchanged: app-servers are touched only after a
390390
// write actually landed, never on a refused/failed serialization attempt.
391391
expect(syncCacheCase).toContain("withCatalogWriteSerialization");
392-
expect(syncCacheCase).toContain("invalidateCodexModelsCacheWithPermit(permit, owningCodexHome)");
392+
// #1931: explicit sync-cache refreshes even when injection is OFF (side profiles).
393+
expect(syncCacheCase).toContain("invalidateCodexModelsCacheWithPermit(permit, owningCodexHome, { allowWhenDesiredDisabled: true })");
393394
const gate = 'if (invalidated.kind === "completed" && invalidated.value)';
394395
expect(syncCacheCase).toContain(gate);
395396
expect(syncCacheCase).toContain("afterCatalogWriteHandleAppServers");

‎tests/commandcode-provider.test.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,8 @@ describe("Command Code provider", () => {
192192
const deepseek = models.find(row => row.id === "deepseek/deepseek-v4-flash")!;
193193
expect(deepseek.contextWindow).toBe(1_000_000);
194194
expect(deepseek.owned_by).toBe("command-code");
195-
expect(deepseek.reasoningEfforts).toEqual([]);
195+
// #1800: discovered models now surface the curated effort table (command-code-efforts.ts).
196+
expect(deepseek.reasoningEfforts).toEqual(["high", "max"]);
196197

197198
const haiku = models.find(row => row.id === "claude-haiku-4-5-20251001")!;
198199
expect(haiku.contextWindow).toBe(200_000);

0 commit comments

Comments
 (0)