google-gemini / generative-ai-python

The official Python library for the Google Gemini API
https://pypi.org/project/google-generativeai/
Apache License 2.0
1.46k stars 288 forks source link

_MultiThreadedRendezvous error #177

Open satishmd opened 8 months ago

satishmd commented 8 months ago

Description of the bug:

when i am trying to ask a question to the model by adding the image ,sometimes i am getting below error

grpc._channel._MultiThreadedRendezvous: <_MultiThreadedRendezvous of RPC that terminated with: status = StatusCode.INTERNAL details = "An internal error has occurred. Please retry or report in https://developers.generativeai.google/guide/troubleshooting" debug_error_string = "UNKNOWN:Error received from peer ipv4:172.217.160.138:443 {created_time:"2024-01-24T11:30:58.841912+00:00", grpc_status:13, grpc_message:"An internal error has occurred. Please retry or report in https://developers.generativeai.google/guide/troubleshooting"}"

the code i am using is below

genai.configure(api_key=GOOGLE_API_KEY) model = genai.GenerativeModel("gemini-pro-vision") img = PIL.Image.open(f"output_images_and_tables/{value}.png") response = model.generate_content([item[1], img], stream=True)

Actual vs expected behavior:

No response

Any other information you'd like to share?

No response

yzeng58 commented 6 months ago

Same here! Did you figure it out?

markmcd commented 3 weeks ago

We are having trouble reproducing this one - if you have any more info on how to repro the issue, it would help. Any environmental information too - e.g. was this colab, are you using a proxy, what OS, etc.

github-actions[bot] commented 1 week ago

Marking this issue as stale since it has been open for 14 days with no activity. This issue will be closed if no further activity occurs.