litellm - 💡(How to fix) Fix [Bug]: test connect Dashscope model failed

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…

Error Message

litellm.BadRequestError: DashscopeException - No static resource api-openai/v1/chat/completions/chat/completions. stack trace: Traceback (most recent call last): File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 930, in acompletion headers, response = await self.make_openai_chat_completion_request( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ...<4 lines>... ) ^ File "/app/.venv/lib/python3.13/site-packages/litellm/litellm_core_utils/logging_utils.py", line 297, in async_wrapper result = await func(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 461, in make_openai_chat_completion_request raise e File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 438, in make_openai_chat_completion_request await openai_aclient.chat.completions.with_raw_response.create( **data, timeout=timeout ) File "/app/.venv/lib/python3.13/site-packages/openai/_legacy_response.py", line 384, in wrapped ret

Code Example

litellm.BadRequestError: DashscopeException - No static resource api-openai/v1/chat/completions/chat/completions.
stack trace: Traceback (most recent call last):
  File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 930, in acompletion
    headers, response = await self.make_openai_chat_completion_request(
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    ...<4 lines>...
    )
    ^
  File "/app/.venv/lib/python3.13/site-packages/litellm/litellm_core_utils/logging_utils.py", line 297, in async_wrapper
    result = await func(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 461, in make_openai_chat_completion_request
    raise e
  File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 438, in make_openai_chat_completion_request
    await openai_aclient.chat.completions.with_raw_response.create(
        **data, timeout=timeout
    )
  File "/app/.venv/lib/python3.13/site-packages/openai/_legacy_response.py", line 384, in wrapped
    ret
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?

A bug happened! the body send to Dashscope has an redundant curly braces

<img width="668" height="754" alt="Image" src="https://github.com/user-attachments/assets/cc149672-1fa7-4e16-b66b-cba3f4f8d296" />

Steps to Reproduce

  1. Add a Dashscope Model
  2. test connect

Relevant log output

litellm.BadRequestError: DashscopeException - No static resource api-openai/v1/chat/completions/chat/completions.
stack trace: Traceback (most recent call last):
  File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 930, in acompletion
    headers, response = await self.make_openai_chat_completion_request(
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    ...<4 lines>...
    )
    ^
  File "/app/.venv/lib/python3.13/site-packages/litellm/litellm_core_utils/logging_utils.py", line 297, in async_wrapper
    result = await func(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 461, in make_openai_chat_completion_request
    raise e
  File "/app/.venv/lib/python3.13/site-packages/litellm/llms/openai/openai.py", line 438, in make_openai_chat_completion_request
    await openai_aclient.chat.completions.with_raw_response.create(
        **data, timeout=timeout
    )
  File "/app/.venv/lib/python3.13/site-packages/openai/_legacy_response.py", line 384, in wrapped
    ret

What part of LiteLLM is this about?

UI Dashboard

What LiteLLM version are you on ?

v1.85.0

Twitter / LinkedIn details

No response

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