Skip to content

"Invalid request: the message at position 64 with role 'assistant' must not be empty" with Kimi K3 #37887

Closed as not planned

Description

@jcsimmo

im getting ""Invalid request: the message at position 64 with role 'assistant' must not be empty" with Kimi K3

Activity

  1. github-actions commented on Jul 20, 2026

    @github-actions
    Contributor

    This issue doesn't fully meet our contributing guidelines.

    What needs to be fixed:

    • No issue template was used — please use the Bug Report template, which requires a Description field with real content, reproduction steps, and environment information (OS, opencode version, provider/model config)
    • The current content is a single line with no context on how to reproduce the issue or what environment it occurs in

    Please edit this issue to address the above within 2 hours, or it will be automatically closed.


    This issue might be a duplicate of existing issues. Please check:

    If you believe this was flagged incorrectly, please let a maintainer know.

  2. github-actions commented on Jul 20, 2026

    @github-actions
    Contributor

    This issue has been automatically closed because it was not updated to meet our contributing guidelines within the 2-hour window.

    Feel free to open a new issue that follows our issue templates.

  3. impptg commented on Aug 31, 2026

    @impptg

    For anyone landing here from search: this error means the replayed history contains an assistant message that serializes with empty content (typically from a mid-turn abort or empty streamed text parts with reasoning models like Kimi K3), and strict providers reject the whole request — bricking the session.

    Two fixes:

    If your session is already bricked and you can't wait: clean the offending assistant rows in ~/.local/share/opencode/opencode.db (empty text parts / reasoning-only steps), then restart the client.

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions