GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — tool_use` ids were found without `tool_result` blocks · Issue #4802 · anomalyco/opencode

tool_use ids were found without tool_result` blocks #4802

New issue
Copy link
New issue
Copy link
Closed as duplicate
Closed as duplicate
tool_use ids were found without tool_result` blocks#4802
Copy link
Assignees
rekram1-node
Labels
bugSomething isn't workingopentuiThis relates to changes in v1.0, now that opencode uses opentui

Description

@berenddeboer
berenddeboer
opened on Nov 26, 2025
Issue body actions

Description

With Anthropic Claude Opus 4.5 (latest)

Seems unrecoverable:

messages.55: `tool_use` ids were found without `tool_result` blocks immediately after:
toolu_01JKfqxRrU8oAPSczPHTGAkZ. Each `tool_use` block must have a corresponding
`tool_result` block in the next message.

Does not want to proceed after this.

OpenCode version

1.0.115

Steps to reproduce

No response

Screenshot and/or share link

No response

Operating System

Ubuntu 24.04

Terminal

Alacritty, tmux

Activity

  1. berenddeboer
    added
    bugSomething isn't working
    on Nov 26, 2025
  2. github-actions
    added
    opentuiThis relates to changes in v1.0, now that opencode uses opentui
    on Nov 26, 2025
  3. rekram1-node
    self-assigned this
    on Nov 26, 2025
  4. github-actions commented on Nov 26, 2025

    @github-actions
    github-actionsBot
    on Nov 26, 2025 – with GitHub Actions
    Contributor
    More actions

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

    • AI_APICallError: tool_use blocks found without corresponding tool_result blocks #2720: AI_APICallError: tool_use blocks found without corresponding tool_result blocks
    • AI_APICallError: tool_use ids were found without tool_result blocks immediately after #1662: AI_APICallError: tool_use ids were found without tool_result blocks immediately after (Claude Pro - Sonnet 4)
    • AI_APICallError: messages.3: tool_use ids were found without tool_result blocks immediately after: toolu_01G5ipgNZWmDHuV6cvzyQpfH. Each tool_use block must have a corresponding tool_result block in the next message. #2214: AI_APICallError: messages.3: tool_use ids were found without tool_result blocks immediately after (occurs when interrupting response mid-flight in plan mode)

    These all report the same error about tool_use blocks not having corresponding tool_result blocks. The issue appears to be a known bug with the messaging format/validation when using Claude models.

    Feel free to ignore if this relates to a specific new trigger or different use case with Claude Opus 4.5.

  5. rekram1-node commented on Nov 26, 2025

    @rekram1-node
    rekram1-node
    on Nov 26, 2025
    Member
    More actions

    okay enoughs enough ill fix this

    The anthropic api has some bug where it corrupts the local state, the client has to account for the discrepency itself

    Until it's fixed you can always do /undo

  6. rekram1-node commented on Nov 26, 2025

    @rekram1-node
    rekram1-node
    on Nov 26, 2025
    Member
    More actions

    im gonna close this as a duplicate but just know this is top of mind to address soon

  7. rekram1-node
    closed this as duplicateon Nov 26, 2025
  8. rekram1-node commented on Nov 27, 2025

    @rekram1-node
    rekram1-node
    on Nov 27, 2025
    Member
    More actions

    @berenddeboer any chance you can send me the file session.json from an export dump:

    opencode export > session.json

    Itll open up a selector if you can choose the session that errored for u

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

Metadata

Metadata

Assignees

  • @rekram1-node
    rekram1-node

Labels

bugSomething isn't workingopentuiThis relates to changes in v1.0, now that opencode uses opentui

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.