Skip to content

Bash tool always returns "(result.stdout ?? "").split is not a function" - shell subprocess never executes #26932

@crdiaz324

Description

@crdiaz324

Description

Every bash tool call fails with the following error returned to the LLM:

(result.stdout ?? "").split is not a function. (In '(result.stdout ?? "").split(\n)', '(result.stdout ?? "").split' is undefined)

The tool appears to complete instantly (duration=0ms in logs) without actually spawning a shell process. The error suggests the tool result handler is receiving a non-string value for stdout (likely null or an abort object) and failing to parse it.

The error is consistent across all commands, including trivial ones like echo "hello".

Plugins

No response

OpenCode version

1.14.48

Steps to reproduce

  1. Start OpenCode (TUI or any mode)
  2. Ask the LLM to run any bash command (e.g. echo "hello" or git status)
  3. Observe the error: "(result.stdout ?? "").split is not a function"
  4. Check logs at ~/.local/share/opencode/log/ — bash tool shows status=completed duration=0, confirming the subprocess never ran

Screenshot and/or share link

Image

Operating System

No response

Terminal

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions