You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Flaky: plugin-hono-server adapter-drain.test.ts "an idle keep-alive connection is released at drain start" reads the socket after a fixed 50 ms sleep #35621
Filing gate: (c) a residual that a card thread's queue eject names. Reported by seat 1's #34575 card thread (PR #35510 audit comment 7018063679). ⛔ Not a claim.
Grade: area:fleet · Bug · flaky test (a timing premise) · every merge-queue group that runs Test Core shard 10 · measured once: merge-queue run 44581618003.
What happened
PR #35510 was ejected from the merge queue (run 44581618003, a group holding only that PR). The failure was in Test Core 10/10, packages/plugins/plugin-hono-serveradapter-drain.test.ts, case "an idle keep-alive connection is released at drain start": expected undefined to be 'keep-alive'.
The test writes the request, then sleep(50), then parses the bytes it has received (around lines 241–243). Under a loaded runner the response hasn't arrived yet, so the header reads as undefined. This is the same class as a fixed timeout.
This is the first occurrence in the 24-hour ledger.
Fix
Wait on the socket for the response (or for its headers) with a bounded deadline, instead of a fixed sleep. Keep the assertion as it is. A shard-local retry, or a longer sleep, is not the fix.
Done when
The case waits for the bytes it asserts on, and a loop run (for example 50 runs) under CPU pressure stays green.
Triage: lands in domain:server · pm:queue; rationale: area:fleet · Bug (flaky: the adapter-drain keep-alive case rests on a timing premise and can eject a merge-queue group on Test Core shard 10) · every group running that shard · measured once → p2 as set.
Claim: PM loop · 2026-11-19 · p2, on the seat's 18:23Z order, dispatched to an os-dev subagent of this area thread. The slot was freed when PR #35626 entered the merge queue.
Area: b1-B
Session: session_01L6bhgTyMahdAdhXSzgy2nt
Account: os-sales
Branch: claude/issue-35621-adapter-drain-keepalive-wait
Worktree: objectstack-issue-35621
Domain: domain:server
Seat: repo:objectstack#1 (area b1-B)
File surface: packages/plugins/plugin-hono-server/src/adapter-drain.test.ts only (test-only). Stop on breach.
Container & model: S, mode:subagent, model: default (opus) — dispatch-gates --tier: no path-derived mandate, effort: medium
Clause-②: no
Metadata-protocol: none
Responsibility: objectstack packages/plugins/plugin-hono-server/src/adapter-drain.test.ts:241-243 (read at origin/main) | none (timing premise in the test) | every merge-queue group running Test Core shard 10; measured once, merge-queue run 44581618003
Thread-read: 7018621938
Premise: holds. On origin/main, the case "an idle keep-alive connection is released at drain start" writes the request, sleeps a fixed 50 ms, then parses whatever bytes have arrived. On a loaded runner the response is not there yet, and the header reads as undefined.
Route (from the card): wait on the socket for the response headers with a bounded deadline instead of the fixed sleep. The assertion is unchanged. No retry, no longer sleep.
Pre-claim lane: the seat assigned this card to area b1-B (18:23Z); test-only.
Pre-claim deps: none; overlap-check runs before each push.
Prior rulings read: none for this file; thread: triage 7018621938; repo: objectstack-ai/objectstack
Serial constraints cleared: in-flight b1-B work is #35523 (packages/verify/**), a different package
{
"issue": 35621,
"status": "done",
"branch": "claude/issue-35621-adapter-drain-keepalive-wait",
"pr": "https://github.com/objectstack-ai/objectstack/pull/35638",
"session": "session_01L6bhgTyMahdAdhXSzgy2nt",
"premise_still_valid": true,
"summary": "Premise held at origin/main e01b8bed: the idle keep-alive case wrote GET /probe, slept a fixed 50 ms, then read the received bytes. Added waitForResponseHead(conn, timeoutMs = 5000) next to rawConnection/splitResponse in adapter-drain.test.ts: it resolves once the response head (through the blank line after the headers) has arrived and rejects with a message naming the bytes received on timeout or early close. The idle keep-alive case now waits on it (assertion unchanged); two other cases whose sleep stood in for waiting for bytes they assert on use it too (the slow-reader case keeps its sleep(100), which also lets the big response call end(), and adds the wait after it; the event-stream case replaces its sleep). Sleeps that hold a request in flight are untouched. Test-only, one file; skip-changeset declared on pr_create (helper absent from built dist/, control present).",
"tests": "At 7db8fd85, under os-verify-lock: `pnpm --filter @objectstack/plugin-hono-server exec vitest run --maxWorkers=2 src/adapter-drain.test.ts && pnpm --filter @objectstack/plugin-hono-server typecheck` -> Test Files 1 passed (1), Tests 12 passed (12), check:test-typecheck OK, VERDICT command-exit 0. Pressure loop: 12 parallel `sh -c 'while :; do :; done'` busy loops (3x the 4 CPUs, load avg ~14.6), each run a fresh `pnpm exec vitest run --maxWorkers=1 src/adapter-drain.test.ts` (whole file). New version: RESULT new: 50 passed, 0 failed of 50. Old version (origin/main file copied under another name for the run, removed by trap): RESULT old: 19 passed, 1 failed of 20; the failure is the reported one (`an idle keep-alive connection is released at drain start` / `AssertionError: expected undefined to be 'keep-alive'`). Caveat stated in the PR: the old loop's failing run 3 fell while this branch's derived gate scripts were also running on the box, which the new loop did not have; a first old loop was invalidated by a script bug (TERM trap did not exit, so later runs found no file) and only its one valid run (pass) is counted. Ablation not done: test timing change, not a pinned behaviour; the old-version loop is the before/after reading.",
"gates": "Local, at 7db8fd85: `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` derived 52 families (stderr line 1: tree objectstack-ai/objectstack at 7db8fd85, 1 path vs merge base e01b8bed0). Ran all 52, exit captured before any pipe: 50 exit 0; `pnpm check:dual-build-cjs-loads` exit 3 and `pnpm check:lean-entry-closure` exit 3 = NOT MEASURED (need whole-workspace dist/; CI runs them). `dispatch-gates --ran` with exit codes: 52 derived, 50 run, 2 NOT-MEASURED (from a recorded exit 3), 0 UNRUN. `node scripts/check-nul-bytes.mjs` exit 0. ① closure build `pnpm --workspace-concurrency=2 --filter '@objectstack/plugin-hono-server^...' build` VERDICT command-exit 0. CI (PR check-runs at report time, head 7db8fd85): Check Changeset success; Type Check (source gates, debt ledger, workspace, consumer gates), Lint (PM dispatch-gates, scoped slot lookup, query-options erasure, tooling self-tests, CI/release/engine, repo & tooling, docs & code guards, ESLint), PR-body guards, Governed Surface Queue Guard, filter, Flag docs, Check PR Size: in_progress; Test Core not yet listed. test:repo not run locally (diff does not touch that project), declared to CI.",
"dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm",
"mcp_calls": "0",
"api_writes": "2 relay strokes (POST /repos/objectstack-ai/objectstack/dispatches via fleet-write): (1) pr_create run 44605625526 -> POST /repos/objectstack-ai/objectstack/pulls (draft #35638), POST /issues/35638/assignees [os-sales], POST /issues/35638/labels [skip-changeset], read back identical; (2) os-dev-report comment on #35621 via post-stamped.mjs -> POST /repos/objectstack-ai/objectstack/issues/35621/comments. Plus 2 git pushes (empty-branch probe, then 7db8fd85; a first push of the tip was refused locally by check:commit-card-trailers for a model name in the co-author trailer, reworded before it ever reached the remote).",
"open_questions": [],
"security_findings": "none",
"out_of_scope_findings": []
}
Delivered · 2026-11-19T21:02Z · PR #35638 merged as eca20d2; this card closed by its Fixes line. The idle keep-alive case in adapter-drain.test.ts now waits, bounded at 5 s, for the response head instead of sleeping a fixed 50 ms. The event-stream and slow-reader cases wait for the bytes they assert on in the same way. The change is test-only. Under CPU pressure the new version passed 50 of 50 runs, and the old version reproduced the failure once in 20.
Activity
objectstack-fleet commentedon Nov 19, 2026
triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH
Triage: lands in
domain:server·pm:queue; rationale: area:fleet · Bug (flaky: theadapter-drainkeep-alive case rests on a timing premise and can eject a merge-queue group on Test Core shard 10) · every group running that shard · measured once → p2 as set.objectstack-fleet commentedon Nov 19, 2026
repo:objectstack#1 · os-sales · session_01L6bhgTyMahdAdhXSzgy2nt
Claim: PM loop · 2026-11-19 · p2, on the seat's 18:23Z order, dispatched to an os-dev subagent of this area thread. The slot was freed when PR #35626 entered the merge queue.
Area: b1-B
Session:
session_01L6bhgTyMahdAdhXSzgy2ntAccount:
os-salesBranch:
claude/issue-35621-adapter-drain-keepalive-waitWorktree:
objectstack-issue-35621Domain:
domain:serverSeat:
repo:objectstack#1(area b1-B)File surface:
packages/plugins/plugin-hono-server/src/adapter-drain.test.tsonly (test-only). Stop on breach.Container & model: S,
mode:subagent,model: default (opus) — dispatch-gates --tier: no path-derived mandate,effort: mediumClause-②: no
Metadata-protocol: none
Responsibility:
objectstack packages/plugins/plugin-hono-server/src/adapter-drain.test.ts:241-243 (read at origin/main) | none (timing premise in the test) | every merge-queue group running Test Core shard 10; measured once, merge-queue run 44581618003Thread-read: 7018621938
Premise: holds. On
origin/main, the case "an idle keep-alive connection is released at drain start" writes the request, sleeps a fixed 50 ms, then parses whatever bytes have arrived. On a loaded runner the response is not there yet, and the header reads asundefined.Route (from the card): wait on the socket for the response headers with a bounded deadline instead of the fixed sleep. The assertion is unchanged. No retry, no longer sleep.
Pre-claim lane: the seat assigned this card to area b1-B (18:23Z); test-only.
Pre-claim deps: none; overlap-check runs before each push.
Prior rulings read: none for this file; thread: triage 7018621938; repo: objectstack-ai/objectstack
Serial constraints cleared: in-flight b1-B work is #35523 (
packages/verify/**), a different packageobjectstack-fleet commentedon Nov 19, 2026
repo:objectstack#1 · os-sales · session_01L6bhgTyMahdAdhXSzgy2nt
os-dev-report
{ "issue": 35621, "status": "done", "branch": "claude/issue-35621-adapter-drain-keepalive-wait", "pr": "https://github.com/objectstack-ai/objectstack/pull/35638", "session": "session_01L6bhgTyMahdAdhXSzgy2nt", "premise_still_valid": true, "summary": "Premise held at origin/main e01b8bed: the idle keep-alive case wrote GET /probe, slept a fixed 50 ms, then read the received bytes. Added waitForResponseHead(conn, timeoutMs = 5000) next to rawConnection/splitResponse in adapter-drain.test.ts: it resolves once the response head (through the blank line after the headers) has arrived and rejects with a message naming the bytes received on timeout or early close. The idle keep-alive case now waits on it (assertion unchanged); two other cases whose sleep stood in for waiting for bytes they assert on use it too (the slow-reader case keeps its sleep(100), which also lets the big response call end(), and adds the wait after it; the event-stream case replaces its sleep). Sleeps that hold a request in flight are untouched. Test-only, one file; skip-changeset declared on pr_create (helper absent from built dist/, control present).", "tests": "At 7db8fd85, under os-verify-lock: `pnpm --filter @objectstack/plugin-hono-server exec vitest run --maxWorkers=2 src/adapter-drain.test.ts && pnpm --filter @objectstack/plugin-hono-server typecheck` -> Test Files 1 passed (1), Tests 12 passed (12), check:test-typecheck OK, VERDICT command-exit 0. Pressure loop: 12 parallel `sh -c 'while :; do :; done'` busy loops (3x the 4 CPUs, load avg ~14.6), each run a fresh `pnpm exec vitest run --maxWorkers=1 src/adapter-drain.test.ts` (whole file). New version: RESULT new: 50 passed, 0 failed of 50. Old version (origin/main file copied under another name for the run, removed by trap): RESULT old: 19 passed, 1 failed of 20; the failure is the reported one (`an idle keep-alive connection is released at drain start` / `AssertionError: expected undefined to be 'keep-alive'`). Caveat stated in the PR: the old loop's failing run 3 fell while this branch's derived gate scripts were also running on the box, which the new loop did not have; a first old loop was invalidated by a script bug (TERM trap did not exit, so later runs found no file) and only its one valid run (pass) is counted. Ablation not done: test timing change, not a pinned behaviour; the old-version loop is the before/after reading.", "gates": "Local, at 7db8fd85: `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` derived 52 families (stderr line 1: tree objectstack-ai/objectstack at 7db8fd85, 1 path vs merge base e01b8bed0). Ran all 52, exit captured before any pipe: 50 exit 0; `pnpm check:dual-build-cjs-loads` exit 3 and `pnpm check:lean-entry-closure` exit 3 = NOT MEASURED (need whole-workspace dist/; CI runs them). `dispatch-gates --ran` with exit codes: 52 derived, 50 run, 2 NOT-MEASURED (from a recorded exit 3), 0 UNRUN. `node scripts/check-nul-bytes.mjs` exit 0. ① closure build `pnpm --workspace-concurrency=2 --filter '@objectstack/plugin-hono-server^...' build` VERDICT command-exit 0. CI (PR check-runs at report time, head 7db8fd85): Check Changeset success; Type Check (source gates, debt ledger, workspace, consumer gates), Lint (PM dispatch-gates, scoped slot lookup, query-options erasure, tooling self-tests, CI/release/engine, repo & tooling, docs & code guards, ESLint), PR-body guards, Governed Surface Queue Guard, filter, Flag docs, Check PR Size: in_progress; Test Core not yet listed. test:repo not run locally (diff does not touch that project), declared to CI.", "dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm", "mcp_calls": "0", "api_writes": "2 relay strokes (POST /repos/objectstack-ai/objectstack/dispatches via fleet-write): (1) pr_create run 44605625526 -> POST /repos/objectstack-ai/objectstack/pulls (draft #35638), POST /issues/35638/assignees [os-sales], POST /issues/35638/labels [skip-changeset], read back identical; (2) os-dev-report comment on #35621 via post-stamped.mjs -> POST /repos/objectstack-ai/objectstack/issues/35621/comments. Plus 2 git pushes (empty-branch probe, then 7db8fd85; a first push of the tip was refused locally by check:commit-card-trailers for a model name in the co-author trailer, reworded before it ever reached the remote).", "open_questions": [], "security_findings": "none", "out_of_scope_findings": [] }Generated by Claude Code
objectstack-fleet commentedon Nov 19, 2026
repo:objectstack#1 · os-sales · session_01L6bhgTyMahdAdhXSzgy2nt
Delivered · 2026-11-19T21:02Z · PR #35638 merged as eca20d2; this card closed by its
Fixesline. The idle keep-alive case inadapter-drain.test.tsnow waits, bounded at 5 s, for the response head instead of sleeping a fixed 50 ms. The event-stream and slow-reader cases wait for the bytes they assert on in the same way. The change is test-only. Under CPU pressure the new version passed 50 of 50 runs, and the old version reproduced the failure once in 20.State:
pm:dispatchedremoved. Left open: none.