This is just copying over the same workaround here: https://github.com/zed-industries/zed/blob/e6679b84df7a36051e0094bc600281fc6aa273bd/crates/agent/src/thread.rs#L1455-L1459 Into the agent2 code. Release Notes: - agent: Fixed an issue where some tool calls in the Zed agent could return an error like "`tool_use` ids were found without `tool_result` blocks immediately after"