Skip to content

[Bug]: UI Wrapper Crash: Attempted to access streaming response content, without having called read() #60597

Description

@mitraphix-design

Bug Description

Image When using the native Gemini provider, executing any workspace tool triggers a red UI error pop-up. The backend correctly processes the stream, but the UI wrapper throws a streaming read error immediately after tool execution. Image

Steps to Reproduce

  1. Configure config.yaml to use the native 'gemini' provider.
  2. Initialize a session in the Hermes Desktop App.
  3. Prompt the agent to execute a workspace tool (e.g., git status, file operations).
  4. Wait for the tool execution to complete.
  5. The red error pop-up appears in the UI immediately after.

Expected Behavior

The tool output should be processed and sent back to the model seamlessly without throwing a UI-level streaming read error pop-up.

Actual Behavior

A red error pop-up appears in the UI stating: "Attempted to access streaming response content, without having called read()".

Affected Component

Other

Messaging Platform (if gateway-related)

No response

Debug Report

N/A - This is a UI-level wrapper/diagnostic artifact triggered by tool execution. Backend httpx logic functions correctly.

Operating System

Windows 11

Python Version

3.11.15

Hermes Version

v0.18.0

Additional Logs / Traceback (optional)

Root Cause Analysis (optional)

No response

Proposed Fix (optional)

The UI monitoring layer or diagnostic tool is attempting to access response.content or response.text on an httpx stream that has already been consumed or closed by the backend's aiter_lines(). The UI wrapper needs to be updated to ignore or correctly handle already-consumed streams.

Are you willing to submit a PR for this?

  • I'd like to fix this myself and submit a PR

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Medium — degraded but workaround existsarea/streamingStreaming responses: gateway delivery, provider wirebugcomp/desktopElectron desktop app (apps/desktop/*)needs-reproBug needs reproduction stepsprovider/geminiGoogle Gemini (AI Studio, Cloud Code)type/bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions