[BUG] Gemini Stream Error: Incomplete JSON segment at the end

Abierto
#2,682 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 3 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
22/100
Tipo de issue
Error
Claridad
Necesita aclaración
Estado de actividad
Activo
Stack tecnológico
typescript
Área
api, backend

Línea de trabajo

The payload names only the error text 'Incomplete JSON segment at the end' from the Gemini context stream path. Start by searching the repository for that message and for the Gemini stream handling around it, then reproduce with a long multi-step task. The payload gives no reproduction that reliably triggers the error and no expected behaviour beyond 'normal result', so a contributor would first need to define what a fix must guarantee.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

bug
Problem (one or two sentences)

A Gemini context stream request sometimes fails and Zoo Code shows this error: Gemini generate context stream error: Incomplete JSON segment at the end.

Context (who is affected and when)

I use the Gemini provider with a direct Google API key and the gemini-flash-lite-latest model. The error occurs at random, but it occurs more often during long tasks. Also common in gemini-flash-latest and gemini-4-hydrogen. Don't know about the other Gemini models.

Reproduction steps
  1. Zoo Code 3.98.2 in VSCodium 1.143.17232 on Windows 10 LTSC.
  2. Do a request that will result in it needing to do some work.
  3. Many errors before working, at random.
Expected result

Normal result

Actual result

Incomplete JSON segment at the end

Variations tried (optional)

No response

App Version

3.98.2

API Provider (optional)

Google Gemini

Model Used (optional)

gemini-flash-lite-latest

Zoo Code Task Links (optional)

No response

Relevant logs or errors (optional)

Lenguaje dominante
TypeScript
Estrellas
2k
Forks
301
Merge medio
3 d 14 h
PR fusionados (30 d)
103

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de Zoo-Code-Org/Zoo-Code

Todos los issues de Zoo-Code-Org/Zoo-Code

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.