9 views
-/https://github.com/berriai/litellm/issues/35236
GitHub · issue

#35236 [Bug]: Gemini Flash 3.6 not working with image_url in tool response

  • State: open
  • Author: @cyberjunk
  • Labels: bug, proxy, llm translation

### Check for existing issues

- [x] I have searched the existing issues and checked that my issue is not a duplicate.

### What happened?

When we send an `image_url` as part of a tool response as last message, like so: ``` { 'role': 'tool', 'name': 'SomeName', 'tool_call_id': 'SomeId', 'is_error': False, 'content': [ { 'type': 'text', 'text': 'SomeText' }, { 'type': 'image_url', 'image_url': { 'url': 'SomeUrl' } } ] } ```

We receive the following error with Gemini Flash 3.6 but 3.5 is working fine: ``` "code": 400 "message": "Requests ending with a model turn are not supported." ```

PS: Using Vertex AI

### Steps to Reproduce

1. Call a tool 2. Add its response as multi-chunk `content` with one chunk being an image url 3. See error

### Relevant log output

```shell

```

### What part of LiteLLM is this about?

Proxy

### What LiteLLM version are you on ?

v1.94.0

### Twitter / LinkedIn details

_No response_

GitHub resolver

Import GitHub neighbors on demand. Results are saved as system ingests.

Refresh page
vote history (1 events)
#0 of 0 · 31d19h2m50s ago — entered · #import:https:::github.com:berriai:litellm post #1810
The left requires deeper provider-specific translation/debugging across multimodal and tool-message paths, with greater compatibility and regression risk. The right is a more localized exception-handling and fallback adjustment with a narrower test surface.
discussed in #import:https:::github.com:berriai:litellm

ranked child groups

no voted pairs yet in this scope

cli
src
spread
search