litellm - 💡(How to fix) Fix [Bug]: image generatoin with gemini image model will crash litellm proxy [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
BerriAI/litellm#25116Fetched 2026-04-08 02:45:02
View on GitHub
Comments
0
Participants
1
Timeline
4
Reactions
0
Author
Participants
Timeline (top)
labeled ×3renamed ×1

Code Example

- model_name: gemini-3-pro-image-preview
      litellm_params:
        model: vertex_ai/gemini-3-pro-image-preview
        vertex_project: "eng"
        vertex_location: "global"
        vertex_credentials: os.environ/GOOGLE_VERTEX_AI_JSON
      model_info:
        mode: image_generation

---

resp = client.images.generate(
            prompt="A red circle", model=model, n=1, size="1024x1024"
        )

---

n/a
RAW_BUFFERClick to expand / collapse

Check for existing issues

  • I have searched the existing issues and checked that my issue is not a duplicate.

What happened?

litellm v1.82.3-stable will crash. It is working fine with v1.81.12-stable.1, I am using google vertax AI, tested gemini-3-pro-image-preview

Steps to Reproduce

  1. deploy litellm using helm, with model config:
    - model_name: gemini-3-pro-image-preview
      litellm_params:
        model: vertex_ai/gemini-3-pro-image-preview
        vertex_project: "eng"
        vertex_location: "global"
        vertex_credentials: os.environ/GOOGLE_VERTEX_AI_JSON
      model_info:
        mode: image_generation
  1. test with openAI python client
        resp = client.images.generate(
            prompt="A red circle", model=model, n=1, size="1024x1024"
        )
  1. the request will succeed, but the litellm pod will crash, couldn't catch any logs.

Relevant log output

n/a

What part of LiteLLM is this about?

Proxy

What LiteLLM version are you on ?

v1.82.3-stable

Twitter / LinkedIn details

No response

extent analysis

TL;DR

Downgrade to v1.81.12-stable.1 to potentially resolve the crashing issue with litellm when using the gemini-3-pro-image-preview model.

Guidance

  • Verify that the issue is specific to the v1.82.3-stable version by testing other versions between v1.81.12-stable.1 and v1.82.3-stable to identify the exact version where the problem started.
  • Check the compatibility of the gemini-3-pro-image-preview model with v1.82.3-stable to ensure it's supported.
  • Test the gemini-3-pro-image-preview model with a different configuration or a different model to isolate if the issue is model-specific.
  • Since no logs are available, consider adding logging configurations to capture more detailed error messages that could help in diagnosing the issue.

Example

No specific code example can be provided without more context on the exact changes between v1.81.12-stable.1 and v1.82.3-stable, but reviewing the changelog or release notes for these versions might offer insights.

Notes

The lack of log output makes it challenging to pinpoint the exact cause of the crash. The solution provided is based on the information that the issue does not occur in v1.81.12-stable.1, suggesting a version-specific problem.

Recommendation

Apply workaround: Downgrade to v1.81.12-stable.1 as it is known to work fine with the gemini-3-pro-image-preview model, allowing for temporary resolution until the issue in v1.82.3-stable is addressed.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING