Skip to content

[BUG] InferenceGatewayAPIError loses status_code and response_data (requests backend, streams) #132

Closed

Description

Summary

The README "Error Handling" section shows InferenceGatewayAPIError carrying the HTTP status and error body (e.status_code, e.response_data). With the default requests backend both are always lost: every HTTP error is raised with status_code=0 and response_data={}.

The root cause is the error handler in _make_request (inference_gateway/client.py lines 171-182). After response.raise_for_status() raises, it checks whether the response object is truthy:

  • line 173: error_data = response.json() if response and response.content else {}
  • line 177: status_code = response.status_code if response else 0

requests.Response.__bool__ returns self.ok, which is False for every 4xx/5xx response, so both lines always fall back. httpx.Response defines no __bool__, so use_httpx=True is not affected. The tests do not catch this because they use Mock() responses, which are always truthy.

The three streaming methods (create_chat_completion_stream, create_response_stream, create_message_stream) have a related gap on both backends. They raise InferenceGatewayAPIError(f"Request failed: {str(e)}") without status_code or response_data (lines 479, 491, 696, 708, 1165, 1177). They also leave connection failures from self.session.post(...) / self.client.stream(...) unwrapped, so these escape as raw requests / httpx exceptions instead of InferenceGatewayError.

Steps to Reproduce

  1. Confirm the root cause offline: r = requests.Response(); r.status_code = 404; bool(r) returns False. _make_request checks this value before it reads status_code and the body.
  2. Create a client with the default backend as the README does: client = InferenceGatewayClient("http://localhost:8080/v1").
  3. Trigger any 4xx/5xx from the gateway, for example call client.create_chat_completion(...) with an invalid token while gateway auth is enabled.
  4. Catch the error as in the README "Error Handling" example and print e.status_code and e.response_data.
  5. Repeat steps 3-4 with client.create_chat_completion_stream(...) (iterate the generator), then once more with the gateway stopped.

Expected Behavior

As the README "Error Handling" example shows, e.status_code holds the HTTP status (for example 401) and e.response_data holds the parsed error body. This should hold on both backends, for streaming and non-streaming calls. Connection failures during streaming calls should be raised as InferenceGatewayError, as they already are for non-streaming calls.

Actual Behavior

  • Non-streaming calls on the default requests backend: e.status_code == 0 and e.response_data == {} for every HTTP error. The status only appears inside the message string (Request failed: 401 Client Error: ...).
  • Streaming calls on either backend: e.status_code is None and e.response_data is None.
  • Streaming calls with the gateway unreachable: a raw requests.exceptions.ConnectionError / httpx.ConnectError is raised, and the README's except InferenceGatewayError branch does not catch it.

Activity

  1. edenreich commented on Sep 25, 2026

    @edenreich
    Contributor

    @infer Can you fix this?

  2. inference-gateway-maintainer commented on Sep 25, 2026

    @inference-gateway-maintainer
    ContributorAuthor

    Model: ollama_cloud/glm-5.3-flash · View Job

    Todos

    • Add issue to Roadmap board (In progress)
    • Checkout/create fix/issue-132 branch
    • Read client.py error handling paths
    • Fix _make_request status_code/response_data loss (requests backend)
    • Fix streaming error handling (status_code, response_data, connection failures)
    • Update/add tests covering real-ish response behavior
    • Run checks, commit, push, open draft PR
    • Set board QA + open [DOCS] follow-up issue
    • Mark PR ready, final verification

    Pull Request

    #139

    ✅ Infer Result: Success

    Fixed. PR: #139 (ready for review, fix(client): carry HTTP status and error body into InferenceGatewayAPIError)

    Root cause and fix

    requests.Response.__bool__ returns self.ok, so every 4xx/5xx response is falsy - the error handler in _make_request tested truthiness before reading status_code and the body, so they always fell back to 0 / {}.

    • Added InferenceGatewayClient._api_error() which builds the error using response is not None (not truthiness), so the real HTTP status and parsed JSON error body are carried on both backends; non-JSON bodies safely fall back to {}. _make_request now delegates to it.
    • All three streaming methods (create_chat_completion_stream, create_response_stream, create_message_stream) now raise InferenceGatewayAPIError with status_code and response_data on both backends (httpx error bodies are read via response.read() inside the stream context before parsing), and connection failures from session.post() / client.stream() are wrapped as InferenceGatewayError instead of escaping as raw requests/httpx exceptions.

    Tests

    • New regression tests use real requests.Response objects (Mock is always truthy, which is exactly why the old tests missed the bug): non-streaming and streaming on both backends assert status_code == 401 and the parsed body, plus a non-JSON-body case and connection-failure cases for all three stream methods on both backends.
    • The synthetic Exception("API Error") stream scenario was replaced with a realistic requests.exceptions.ConnectionError.
    • task lint (black, isort, mypy) and task test pass: 47 passed, 1 xfailed (pre-existing, unrelated).

    Tracking

    Model: ollama_cloud/glm-5.3-flash · Exit Code: 0 · Duration: 7m 56s

    Tokens: 4,387,795 in · 36,113 out · 4,423,908 total (42 requests)

    Tool calls: 53 total · 100% success rate

    Traces
    Session: 1790376627-03c43da2
    
    session (headless, success)                                                                        7m48s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 8.8s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       8.7s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     8.7s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             8.7s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 8.7s
    ├── execute_tool TodoWrite call_zthjpb6z                                                            91µs
    ├── execute_tool Bash call_s4a39mvj                                                                392ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 4.3s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       4.3s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     4.3s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             4.3s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 4.3s
    ├── execute_tool Bash call_r498p6f2                                                                 1.7s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 5.3s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       5.3s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     5.3s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             5.3s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 5.3s
    ├── execute_tool Bash call_mozs6fcf                                                                 1.0s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 3.0s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       3.0s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     3.0s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             3.0s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 3.0s
    ├── execute_tool TodoWrite call_35ehko7c                                                            62µs
    ├── execute_tool Bash call_ejnrh8x7                                                                  7ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 3.0s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       3.0s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     3.0s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             3.0s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 3.0s
    ├── execute_tool Bash call_nkwbfy5h                                                                 1.4s
    ├── execute_tool Read call_h2cbp8xp                                                                  1ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                52.6s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      52.6s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    52.6s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            52.6s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                52.6s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 2.5s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       2.5s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     2.5s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             2.5s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 2.5s
    ├── execute_tool Read call_dc3qg8ub                                                                459µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                55.2s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      55.2s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    55.1s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            55.1s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                55.1s
    ├── chat ollama_cloud/glm-5.3-flash                                                                37.5s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      37.5s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    37.4s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            37.4s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                37.4s
    ├── execute_tool Read call_yucb5b00                                                                233µs
    ├── execute_tool Read call_hj6l8ehh                                                                244µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 8.2s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       8.2s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     8.2s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             8.2s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 8.2s
    ├── execute_tool Bash call_f1vw43nb                                                                 71ms [error: tool_error]
    ├── chat ollama_cloud/glm-5.3-flash                                                                 3.6s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       3.5s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     3.5s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             3.5s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 3.5s
    ├── execute_tool Bash call_prncdgh1                                                                 47ms [error: tool_error]
    ├── chat ollama_cloud/glm-5.3-flash                                                                 2.7s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       2.7s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     2.7s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             2.7s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 2.7s
    ├── execute_tool Bash call_4zqusdgj                                                                16.2s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.6s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.5s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.5s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.5s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.5s
    ├── execute_tool Bash call_gzyr6iff                                                                 1.3s
    ├── chat ollama_cloud/glm-5.3-flash                                                                37.5s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      37.5s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    37.4s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            37.4s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                37.4s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 2.6s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       2.5s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     2.5s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             2.5s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 2.5s
    ├── execute_tool TodoWrite call_dfedtywj                                                            82µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 8.1s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       8.1s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     8.1s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             8.1s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 8.1s
    ├── execute_tool MultiEdit call_0643ap8o                                                             1ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                23.8s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      23.8s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    23.8s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            23.8s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                23.8s
    ├── execute_tool TodoWrite call_dzg3h289                                                            58µs
    ├── execute_tool MultiEdit call_nickkjkd                                                           905µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 2.7s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       2.7s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     2.6s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             2.6s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 2.6s
    ├── execute_tool Bash call_hmt70hr3                                                                 1.0s [error: tool_error]
    ├── chat ollama_cloud/glm-5.3-flash                                                                 4.0s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       4.0s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     3.9s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             3.9s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 3.9s
    ├── execute_tool Read call_qggb2kyg                                                                166µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                13.2s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      13.2s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    13.1s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            13.1s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                13.1s
    ├── execute_tool Bash call_edvnfu1n                                                                  5ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                21.3s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      21.2s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    21.2s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            21.2s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                21.2s
    ├── execute_tool Write call_hun412yr                                                               705µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.5s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.4s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.4s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.4s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.4s
    ├── execute_tool Bash call_gw24e81i                                                                 29ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.5s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.4s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.4s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.4s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.4s
    ├── execute_tool Bash call_1g928l0l                                                                 1.2s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.3s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.2s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.2s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.2s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.2s
    ├── execute_tool Bash call_992ws4mj                                                                 5.3s
    ├── chat ollama_cloud/glm-5.3-flash                                                                11.4s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      11.3s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    11.3s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            11.3s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                11.3s
    ├── execute_tool Bash call_2811wp4z                                                                 1.5s [error: tool_error]
    ├── chat ollama_cloud/glm-5.3-flash                                                                12.8s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      12.8s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    12.7s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            12.7s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                12.7s
    ├── execute_tool Edit call_0x7s9o09                                                                125µs [error: tool_error]
    ├── chat ollama_cloud/glm-5.3-flash                                                                 2.0s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       2.0s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     2.0s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             2.0s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 2.0s
    ├── execute_tool Read call_rpix27ix                                                                183µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 4.4s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       4.4s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     4.3s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             4.3s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 4.3s
    ├── execute_tool MultiEdit call_9g6vx4yz                                                           931µs [error: tool_error]
    ├── chat ollama_cloud/glm-5.3-flash                                                                24.9s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                      24.8s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]    24.8s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                            24.8s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                24.8s
    ├── execute_tool Grep call_mke6trfl                                                                699µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 9.2s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       9.2s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     9.2s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             9.2s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 9.2s
    ├── execute_tool Write call_yaqhdy9q                                                               659µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.4s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.4s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.4s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.4s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.4s
    ├── execute_tool Bash call_jmpviyb7                                                                 29ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.8s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.8s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.8s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.8s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.8s
    ├── execute_tool Bash call_0ahs1bm5                                                                769ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.3s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.3s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.3s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.3s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.3s
    ├── execute_tool Bash call_r8h68afg                                                                965ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 6.1s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       6.0s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     6.0s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             6.0s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 6.0s
    ├── execute_tool Bash call_pitqia18                                                                685ms
    ├── execute_tool Bash call_31uxxstf                                                                  5ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 3.4s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       3.4s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     3.3s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             3.3s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 3.3s
    ├── execute_tool TodoWrite call_jamfusm0                                                            60µs
    ├── execute_tool Bash call_7xihh4sy                                                                  6ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 2.2s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       2.2s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     2.1s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             2.1s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 2.1s
    ├── execute_tool Bash call_96d2ijxt                                                                458ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 4.3s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       4.3s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     4.3s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             4.3s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 4.3s
    ├── execute_tool Bash call_vsft7noq                                                                 1.4s
    ├── execute_tool Write call_7tzz4ezw                                                               886µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.7s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.6s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.6s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.6s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.6s
    ├── execute_tool Bash call_v7xdd1tc                                                                 2.2s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 5.1s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       5.0s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     5.0s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             5.0s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 5.0s
    ├── execute_tool Bash call_oir9fzpw                                                                787ms
    ├── execute_tool WebFetch call_pmx2r3tv                                                            117ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 3.9s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       3.9s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     3.8s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             3.8s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 3.8s
    ├── execute_tool Write call_iqwk4dwq                                                               764µs
    ├── chat ollama_cloud/glm-5.3-flash                                                                 1.9s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       1.8s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     1.8s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             1.8s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 1.8s
    ├── execute_tool Bash call_gpqbsyvl                                                                 1.2s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 4.7s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       4.7s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     4.6s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             4.6s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 4.6s
    ├── execute_tool Memory call_55cde8vd                                                               1.2s
    ├── execute_tool Bash call_4wm8jl7b                                                                 1.2s
    ├── chat ollama_cloud/glm-5.3-flash                                                                 2.3s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       2.3s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     2.2s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             2.2s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 2.2s
    ├── execute_tool Bash call_7269zazq                                                                  4ms
    ├── execute_tool Bash call_e5582ezn                                                                  4ms
    ├── execute_tool Bash call_9i1z5t6l                                                                410ms
    ├── chat ollama_cloud/glm-5.3-flash                                                                 3.4s
    │   ╰── POST /v1/chat/completions [inference-gateway, server]                                       3.3s
    │       ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     3.3s
    │           ╰── POST /proxy/:provider/*path [inference-gateway, server]                             3.3s
    │               ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 3.3s
    ├── execute_tool TodoWrite call_06asvdit                                                            71µs
    ╰── chat ollama_cloud/glm-5.3-flash                                                                 4.5s
        ╰── POST /v1/chat/completions [inference-gateway, server]                                       4.4s
            ╰── POST 127.0.0.1:8080/proxy/ollama_cloud/chat/completions [inference-gateway, client]     4.4s
                ╰── POST /proxy/:provider/*path [inference-gateway, server]                             4.4s
                    ╰── POST ollama.com/v1/chat/completions [inference-gateway, client]                 4.4s
    
    Stats
    Tool Calls
    
    ╭───────────┬───────┬───────┬────────╮
    │ Tool      │ Calls │ Fail% │ Avg    │
    ├───────────┼───────┼───────┼────────┤
    │ Bash      │ 30    │ 13%   │ 1377ms │
    │ TodoWrite │ 6     │ 0%    │ 62µs   │
    │ Read      │ 6     │ 0%    │ 458µs  │
    │ Write     │ 4     │ 0%    │ 752µs  │
    │ MultiEdit │ 3     │ 33%   │ 1ms    │
    │ Grep      │ 1     │ 0%    │ 700µs  │
    │ Memory    │ 1     │ 0%    │ 1177ms │
    │ Edit      │ 1     │ 100%  │ 60µs   │
    │ WebFetch  │ 1     │ 0%    │ 117ms  │
    ╰───────────┴───────┴───────┴────────╯
    
    Token Usage
    
    ╭────────────────────────────┬─────────┬─────────┬────────────┬─────────┬──────╮
    │ Model                      │ Prompt  │ Cached  │ Completion │ Total   │ Cost │
    ├────────────────────────────┼─────────┼─────────┼────────────┼─────────┼──────┤
    │ ollama_cloud/glm-5.3-flash │ 4572647 │ 4058880 │ 60689      │ 4633336 │ -    │
    ╰────────────────────────────┴─────────┴─────────┴────────────┴─────────┴──────╯
    
    Sessions
    
    ╭───────────┬──────────┬──────────╮
    │ Execution │ Mode     │ Sessions │
    ├───────────┼──────────┼──────────┤
    │ headless  │ headless │ 1        │
    ╰───────────┴──────────┴──────────╯
    

    Triggered by edenreich · Infer Action · OSS

  3. moved this from Todo to In progress in 2026on Sep 25, 2026
  4. inference-gateway-releaser commented on Sep 26, 2026

    @inference-gateway-releaser
    Contributor

    🎉 This issue has been resolved in version 0.21.1 🎉

    The release is available on GitHub release

    Your semantic-release bot 📦🚀

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugreleased

    Type

    Projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions