We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0dfa34e commit 5e3edd2Copy full SHA for 5e3edd2
api/core/model_runtime/model_providers/openai_api_compatible/llm/llm.py
@@ -478,6 +478,10 @@ def get_tool_call(tool_call_id: str):
478
usage=usage,
479
)
480
break
481
+ # handle the error here. for issue #11629
482
+ if chunk_json.get("error") and chunk_json.get("choices") is None:
483
+ raise ValueError(chunk_json.get("error"))
484
+
485
if chunk_json:
486
if u := chunk_json.get("usage"):
487
usage = u
0 commit comments