Skip to content

Gemini Live gets stuck in a 1011 resume loop and the interview ends itself #198

Description

@winter77777

Observed behavior

With the default gemini-3.1-flash-live-preview, Gemini closes the Live socket with 1011 "Internal error encountered". codetrial resumes the session, but each resumed session closes again within 10-20 seconds. After 8 in a row codetrial ends the interview, so the practice session is lost with no report.

Sometimes it happens late (about 13 minutes in, after the interview had been working fine), sometimes almost immediately (1011 within 30 seconds in two sessions in a row after a restart). Right before the loop, Gemini often stops responding ("no output 20s after a prompt").

Expected behavior

The interview should keep going after a 1011, or at least recover once instead of looping until it gives up.

Reproduction

  1. Set GOOGLE_API_KEY and the LiveKit settings in config/codetrial.env.local, leave GEMINI_LIVE_MODEL unset.
  2. Start codetrial and open an interview
  3. Within a few seconds to ~13 minutes, Gemini closes with 1011 and every resume closes again until codetrial ends the interview.

CodeTrial version

codetrial 0.1.0 (77bff68)

Environment

OS: Windows 11 (x86_64), prebuilt codetrial-x86_64-pc-windows-msvc.exe
Browser: Chrome 154.0.8037.92
Gemini model: gemini-3.1-flash-live-preview (default)

Sanitized evidence

timing: 0.74s from the candidate finishing to the reply starting
prompt: at=13:16.737 kind=nudge id=11 ...
timing: no output 20s after a prompt; returning the floor at=13:38.727
Gemini closed the session: code=1011 reason=Internal error encountered.
replacement: at=13:53.821 resumed=true checkpoint_age=4s owed=true (candidate=false prompt=11 tool=false) id=11 ...
Gemini closed the session: code=1011 reason=Internal error encountered.
replacement: at=14:05.791 resumed=true checkpoint_age=9s owed=true (candidate=false prompt=12 tool=false) id=12 ...
Gemini closed the session: code=1011 reason=Internal error encountered.
replacement: at=14:17.313 resumed=true checkpoint_age=8s ...
Gemini closed the session: code=1011 reason=Internal error encountered.
replacement: at=14:32.249 resumed=true checkpoint_age=inherited ...
[... 3 more close/resume pairs, 10-25s apart ...]
Gemini closed the session: code=1011 reason=Internal error encountered.
Gemini closed 8 sockets in a row without one of them lasting; ending interview room=interview-iadrs09s

Public data confirmation

  • I removed credentials, session tokens, candidate recordings, and personal interview content from this public report.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions