[GH-ISSUE #24639] issue: Error processing chat payload: 'NoneType' object has no attribute 'startswith' #123679

Closed
opened 2026-05-21 03:06:43 -05:00 by GiteaMirror · 2 comments
Owner

Originally created by @Arondight on GitHub (May 13, 2026).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/24639

Check Existing Issues

  • I have searched for any existing and/or related issues.
  • I have searched for any existing and/or related discussions.
  • I have also searched in the CLOSED issues AND CLOSED discussions and found no related items (your issue might already be addressed on the development branch!).
  • I am using the latest version of Open WebUI.

Installation Method

Docker

Open WebUI Version

v.0.9.5

Ollama Version (if applicable)

No response

Operating System

CentOS Stream 10

Browser (if applicable)

No response

Confirmation

  • I have read and followed all instructions in README.md.
  • I am using the latest version of both Open WebUI and Ollama.
  • I have included the browser console logs.
  • I have included the Docker container logs.
  • I have provided every relevant configuration, setting, and environment variable used in my setup.
  • I have clearly listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc).
  • I have documented step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation. My steps:
  • Start with the initial platform/version/OS and dependencies used,
  • Specify exact install/launch/configure commands,
  • List URLs visited, user input (incl. example values/emails/passwords if needed),
  • Describe all options and toggles enabled or changed,
  • Include any files or environmental changes,
  • Identify the expected and actual result at each stage,
  • Ensure any reasonably skilled user can follow and hit the same issue.

Expected Behavior

Opencode connect v0.9.2 works well, but v0.9.5 get an error log, it should be fixed.

Actual Behavior

clipboard_2026-05-13_10-00

and the backend log:

2026-05-13 01:57:13.339 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:49112 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 01:57:23.343 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:53614 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 01:57:43.340 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:42436 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 01:58:03.344 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:57974 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 01:58:23.344 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:53386 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 01:58:43.339 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:43976 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 01:59:03.337 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:53872 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 01:59:23.344 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:45584 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 01:59:33.184 | ERROR    | open_webui.main:process_chat:2013 - Error processing chat payload: 'NoneType' object has no attribute 'startswith'                                 
2026-05-13 01:59:33.185 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 223.70.159.239:0 - "POST /api/chat/completions HTTP/1.1" 400                                      
2026-05-13 01:59:43.339 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:55556 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 02:00:03.341 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:54274 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 02:00:23.344 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:51878 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 02:00:42.835 | ERROR    | open_webui.main:process_chat:2013 - Error processing chat payload: 'NoneType' object has no attribute 'startswith'                                 
2026-05-13 02:00:42.835 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 223.70.159.239:0 - "POST /api/chat/completions HTTP/1.1" 400                                      
2026-05-13 02:00:42.932 | ERROR    | open_webui.main:process_chat:2013 - Error processing chat payload: 'NoneType' object has no attribute 'startswith'                                 
2026-05-13 02:00:42.933 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 223.70.159.239:0 - "POST /api/chat/completions HTTP/1.1" 400                                      
2026-05-13 02:00:43.340 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:44012 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 02:01:03.341 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:54700 - "GET /metrics HTTP/1.1" 200                                                     
2026-05-13 02:01:23.342 | INFO     | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:41822 - "GET /metrics HTTP/1.1" 200

Steps to Reproduce

steps as https://github.com/anomalyco/opencode/pull/18306#issuecomment-4432435576

Logs & Screenshots

See Actual Behavior.

Additional Information

No response

Originally created by @Arondight on GitHub (May 13, 2026). Original GitHub issue: https://github.com/open-webui/open-webui/issues/24639 ### Check Existing Issues - [x] I have searched for any existing and/or related issues. - [x] I have searched for any existing and/or related discussions. - [x] I have also searched in the CLOSED issues AND CLOSED discussions and found no related items (your issue might already be addressed on the development branch!). - [x] I am using the latest version of Open WebUI. ### Installation Method Docker ### Open WebUI Version v.0.9.5 ### Ollama Version (if applicable) _No response_ ### Operating System CentOS Stream 10 ### Browser (if applicable) _No response_ ### Confirmation - [x] I have read and followed all instructions in `README.md`. - [x] I am using the latest version of **both** Open WebUI and Ollama. - [x] I have included the browser console logs. - [x] I have included the Docker container logs. - [x] I have **provided every relevant configuration, setting, and environment variable used in my setup.** - [x] I have clearly **listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup** (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc). - [x] I have documented **step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation**. My steps: - Start with the initial platform/version/OS and dependencies used, - Specify exact install/launch/configure commands, - List URLs visited, user input (incl. example values/emails/passwords if needed), - Describe all options and toggles enabled or changed, - Include any files or environmental changes, - Identify the expected and actual result at each stage, - Ensure any reasonably skilled user can follow and hit the same issue. ### Expected Behavior Opencode connect v0.9.2 works well, but v0.9.5 get an error log, it should be fixed. ### Actual Behavior <img width="1729" height="921" alt="clipboard_2026-05-13_10-00" src="https://github.com/user-attachments/assets/356e779d-0e6e-41b1-8675-3ac6e42f1812" /> and the backend log: ``` 2026-05-13 01:57:13.339 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:49112 - "GET /metrics HTTP/1.1" 200 2026-05-13 01:57:23.343 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:53614 - "GET /metrics HTTP/1.1" 200 2026-05-13 01:57:43.340 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:42436 - "GET /metrics HTTP/1.1" 200 2026-05-13 01:58:03.344 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:57974 - "GET /metrics HTTP/1.1" 200 2026-05-13 01:58:23.344 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:53386 - "GET /metrics HTTP/1.1" 200 2026-05-13 01:58:43.339 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:43976 - "GET /metrics HTTP/1.1" 200 2026-05-13 01:59:03.337 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:53872 - "GET /metrics HTTP/1.1" 200 2026-05-13 01:59:23.344 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:45584 - "GET /metrics HTTP/1.1" 200 2026-05-13 01:59:33.184 | ERROR | open_webui.main:process_chat:2013 - Error processing chat payload: 'NoneType' object has no attribute 'startswith' 2026-05-13 01:59:33.185 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 223.70.159.239:0 - "POST /api/chat/completions HTTP/1.1" 400 2026-05-13 01:59:43.339 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:55556 - "GET /metrics HTTP/1.1" 200 2026-05-13 02:00:03.341 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:54274 - "GET /metrics HTTP/1.1" 200 2026-05-13 02:00:23.344 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:51878 - "GET /metrics HTTP/1.1" 200 2026-05-13 02:00:42.835 | ERROR | open_webui.main:process_chat:2013 - Error processing chat payload: 'NoneType' object has no attribute 'startswith' 2026-05-13 02:00:42.835 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 223.70.159.239:0 - "POST /api/chat/completions HTTP/1.1" 400 2026-05-13 02:00:42.932 | ERROR | open_webui.main:process_chat:2013 - Error processing chat payload: 'NoneType' object has no attribute 'startswith' 2026-05-13 02:00:42.933 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 223.70.159.239:0 - "POST /api/chat/completions HTTP/1.1" 400 2026-05-13 02:00:43.340 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:44012 - "GET /metrics HTTP/1.1" 200 2026-05-13 02:01:03.341 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:54700 - "GET /metrics HTTP/1.1" 200 2026-05-13 02:01:23.342 | INFO | uvicorn.protocols.http.httptools_impl:send:483 - 10.89.3.1:41822 - "GET /metrics HTTP/1.1" 200 ``` ### Steps to Reproduce steps as https://github.com/anomalyco/opencode/pull/18306#issuecomment-4432435576 ### Logs & Screenshots See Actual Behavior. ### Additional Information _No response_
GiteaMirror added the bug label 2026-05-21 03:06:43 -05:00
Author
Owner

@owui-terminator[bot] commented on GitHub (May 13, 2026):

🔍 Related Issues Found

I found some existing issues that might be related. Please check if any of these are duplicates or contain helpful solutions:

  1. 🟣 #24550 bug: NoneType object has no attribute 'startswith' — all /api/v1/chat/completions calls return 400 (v0.9.5, direct connections)
    This is the closest match: it reports the same 'NoneType' object has no attribute 'startswith' error on chat completions in v0.9.5, specifically for external/direct API clients. The new issue also shows the same backend log and an external client (opencode) failing via /api/chat/completions.
    by ThefloorMiner

  2. 🟣 #24575 bug: 'NoneType' object has no attribute 'startswith' on /api/chat/completions when external client omits parent_id
    This issue is about the same exception occurring when an external client calls /api/chat/completions without parent_id. The new report is also an external OpenAI-compatible client integration failing with the same startswith error.
    by Ghosterme-dev · bug

  3. 🟣 #24603 issue: opencode api access Bad Request: {"detail":"'NoneType' object has no attribute 'startswith'"}
    This is the same opencode-related failure and same error string, just reported on v0.9.6. It is highly relevant because the new issue is explicitly about opencode connect and the same backend crash signature.
    by vibeopsde · bug

  4. 🟣 #24564 Issue #24564
    This issue matches the identical error on /api/chat/completions and indicates a general API-call regression in chat payload processing. It is relevant because the new issue shows the same server-side failure path and HTTP 400 response.
    by unknown


💡 If your issue is a duplicate, please close it and add any additional details to the existing issue instead.

This comment was generated automatically. React with 👍 if helpful, 👎 if not.

<!-- gh-comment-id:4436927156 --> @owui-terminator[bot] commented on GitHub (May 13, 2026): <!-- terminator-bot:related-issues-reply --> 🔍 **Related Issues Found** I found some existing issues that might be related. Please check if any of these are duplicates or contain helpful solutions: 1. 🟣 [#24550](https://github.com/open-webui/open-webui/issues/24550) **bug: NoneType object has no attribute 'startswith' — all /api/v1/chat/completions calls return 400 (v0.9.5, direct connections)** *This is the closest match: it reports the same `'NoneType' object has no attribute 'startswith'` error on chat completions in v0.9.5, specifically for external/direct API clients. The new issue also shows the same backend log and an external client (opencode) failing via `/api/chat/completions`.* *by ThefloorMiner* 2. 🟣 [#24575](https://github.com/open-webui/open-webui/issues/24575) **bug: 'NoneType' object has no attribute 'startswith' on /api/chat/completions when external client omits parent_id** *This issue is about the same exception occurring when an external client calls `/api/chat/completions` without `parent_id`. The new report is also an external OpenAI-compatible client integration failing with the same `startswith` error.* *by Ghosterme-dev · `bug`* 3. 🟣 [#24603](https://github.com/open-webui/open-webui/issues/24603) **issue: opencode api access Bad Request: {"detail":"'NoneType' object has no attribute 'startswith'"}** *This is the same opencode-related failure and same error string, just reported on v0.9.6. It is highly relevant because the new issue is explicitly about opencode connect and the same backend crash signature.* *by vibeopsde · `bug`* 4. 🟣 [#24564](https://github.com/open-webui/open-webui/issues/24564) **Issue #24564** *This issue matches the identical error on `/api/chat/completions` and indicates a general API-call regression in chat payload processing. It is relevant because the new issue shows the same server-side failure path and HTTP 400 response.* *by unknown* --- 💡 If your issue is a duplicate, please close it and add any additional details to the existing issue instead. *This comment was generated automatically.* React with 👍 if helpful, 👎 if not.
Author
Owner

@Arondight commented on GitHub (May 13, 2026):

dup of #24553 and close

<!-- gh-comment-id:4437131593 --> @Arondight commented on GitHub (May 13, 2026): dup of #24553 and close
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#123679