Skip to content

Recover an interviewer that stops answering - #202

Merged
jserv merged 1 commit into
mainfrom
report
Oct 1, 2026
Merged

jserv merged 1 commit into
mainfrom
report

Conversation

@jserv

@jserv jserv commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

A Gemini Live socket can stay connected and answer pings while never replying to a turn, and without a GoAway nothing replaced it, so the candidate sat on "Listening" until they ended the session. A reply owed or under way that produces no output for CODETRIAL_GEMINI_REPLY_TIMEOUT_S (45 s by default, bounded to 20-120) now replaces the socket and asks the resumed or cold replacement for the reply still owed; the room shows "Thinking..." once a reply is four seconds late; an unanswered socket never resets the restart budget, and a spent budget ends the interview with reason interviewer_unavailable and a report rather than with none. The same pass stops a stale turn ending (after an interruption or a stalled generation) from settling a newer reply, and stops a stalled close acknowledgement from holding the interview open until the deadline.

Verified with scripts/test.sh on the rebased branch: 1046 Rust tests, the hook suite, ESLint and Prettier all pass. New unit tests include one that replays every sequence of up to five room-loop steps (transcripts, prompts, output, turn endings, pause, resumed and cold replacement, stall ticks) through the production functions and checks that owed replies are never lost and always have a deadline; reintroducing each bug found in review makes a test fail. The Playwright suite ran against a local Chromium 130 (Playwright has no Chromium build for Ubuntu 20.04): 767 of 772 pass, and the 5 failures (four pdf.js tests and the Run-tests shortcut pause test) fail the same way on origin/main there.

The live prompt moves to 18 and the bundle to 26, since a cold briefing can now carry the owed-reply request. A turn Gemini completes with no output is taken as a deliberate silence and logged, not recovered. A close requested before a pause is still acted on after the resume, as ready_to_close documents. Report generation failing on a 503 is left to #97.

Closes #95

cubic-dev-ai[bot]

This comment was marked as resolved.

Comment thread web/lib.js Outdated
Comment thread docs/provider-cost-and-degradation.md Outdated
cubic-dev-ai[bot]

This comment was marked as resolved.

cubic-dev-ai[bot]

This comment was marked as resolved.

@jserv
jserv force-pushed the report branch 2 times, most recently from 21e4744 to 1b07840 Compare October 1, 2026 22:32
A Gemini socket could stay connected and answer pings while never
replying to a turn, and without a GoAway nothing replaced it, so the
candidate sat on "Listening" until they gave up (#95). A reply owed or
under way that produces no output for CODETRIAL_GEMINI_REPLY_TIMEOUT_S
(45 by default, 20 to 120) now replaces the socket and asks the resumed
or cold replacement for the reply still owed. Such a socket never counts
as healthy for the restart budget, and a spent budget ends the interview
with the new end reason interviewer_unavailable and a report.

The room publishes thinking once a reply is four seconds late, which
the browser already labels and which now closes a replay response
window, as the replay note says. A pause or a candidate's thinking hold
is never taken for a stall, and a turn completed with no output is
logged as a deliberate silence, not recovered. The late ending of an
interrupted or stalled turn no longer settles a newer reply, a pause no
longer waits on a stalled generation, and a stalled close
acknowledgement no longer holds the interview open. Asking for the
owed reply in a cold briefing moves the live prompt to 18 and the
bundle to 26.

Closes #95
@jserv
jserv merged commit 9271993 into main Oct 1, 2026
12 checks passed
@jserv
jserv deleted the report branch October 1, 2026 23:22
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.

Agent becomes unresponsive during interview and final report is INCOMPLETE

2 participants