[GH-ISSUE #9404] Web search is not working in 0.5.9 Search returns SyntaxError: Unexpected token '<', "<html> <h"... is not valid JSON #15491

Closed
opened 2026-04-19 21:40:44 -05:00 by GiteaMirror · 5 comments
Owner

Originally created by @hillzzz on GitHub (Feb 5, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/9404

Bug Report

open-webui version 0.5.9
Any search request starts but returns
Search returns SyntaxError: Unexpected token '<', "<html> <h"... is not valid JSON
Using latest docker version of open-webui
Environment is Jetson AGX Orin
Model used - tested with 20 models all Llama 3.1 3.2, Mistral, Nemotron
Failure started as soon as open-webui was upgraded to 0.5.9
Might be related to [[Bug]DuckDuckGo Web Search is broken #9283

Important Notes

  • Before submitting a bug report: Please check the Issues or Discussions section to see if a similar issue or feature request has already been posted. It's likely we're already tracking it! If you’re unsure, start a discussion post first. This will help us efficiently focus on improving the project.

  • Collaborate respectfully: We value a constructive attitude, so please be mindful of your communication. If negativity is part of your approach, our capacity to engage may be limited. We’re here to help if you’re open to learning and communicating positively. Remember, Open WebUI is a volunteer-driven project managed by a single maintainer and supported by contributors who also have full-time jobs. We appreciate your time and ask that you respect ours.

  • Contributing: If you encounter an issue, we highly encourage you to submit a pull request or fork the project. We actively work to prevent contributor burnout to maintain the quality and continuity of Open WebUI.

  • Bug reproducibility: If a bug cannot be reproduced with a :main or :dev Docker setup, or a pip install with Python 3.11, it may require additional help from the community. In such cases, we will move it to the "issues" Discussions section due to our limited resources. We encourage the community to assist with these issues. Remember, it’s not that the issue doesn’t exist; we need your help!

Note: Please remove the notes above when submitting your post. Thank you for your understanding and support!


Installation Method

Latest docker
[Describe the method you used to install the project, e.g., git clone, Docker, pip, etc.]

run with:
docker run -d --network=host -v open-webui:/app/backend/data -e OLLAMA_BASE_URL=http://127.0.0.1:11434 --name open-webui --restart always ghcr.io/open-webui/open-webui:cuda
on the jetson Platform you have to use " --network=host" to get the networking to interface with the OS network.

Environment

  • Open WebUI Version: [e.g., v0.3.11]

  • Ollama (if applicable): [e.g., v0.2.0, v0.1.32-rc1]

  • Operating System: [e.g., Windows 10, macOS Big Sur, Ubuntu 20.04]

  • Browser (if applicable): [e.g., Chrome 100.0, Firefox 98.0]

Confirmation:

  • I have read and followed all the instructions provided in the README.md.
  • I am on 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 the exact steps to reproduce the bug in the "Steps to Reproduce" section below.

Expected Behavior:

the model opens a search and searches 3 websites and returns a valid response

Actual Behavior:

the model searches 3 sites and then returns the message SyntaxError: Unexpected token '<', "<html> <h"... is not valid JSON

Description

Bug Summary:
The model searches 3 sites and then after a very long delay 10> mins, returns the message SyntaxError: Unexpected token '<', "<html> <h"... is not valid JSON

Reproduction Details

Steps to Reproduce:
load 0.5.9 docker instance, choose any model, select websearch, and search fails.

Logs and Screenshots

Browser Console Logs:
[Include relevant browser console logs, if applicable]

Docker Container Logs:
[Include relevant Docker container logs, if applicable]

Screenshots/Screen Recordings (if applicable):
[Attach any relevant screenshots to help illustrate the issue]

Additional Information

On the Jetson AGX Orin you can't use docker internal network run with:
docker run -d --network=host -v open-webui:/app/backend/data -e OLLAMA_BASE_URL=http://127.0.0.1:11434 --name open-webui --restart always ghcr.io/open-webui/open-webui:cuda
on the jetson Platform you have to use " --network=host" to get the networking to interface with the OS network.

Note

If the bug report is incomplete or does not follow the provided instructions, it may not be addressed. Please ensure that you have followed the steps outlined in the README.md and troubleshooting.md documents, and provide all necessary information for us to reproduce and address the issue. Thank you!

Originally created by @hillzzz on GitHub (Feb 5, 2025). Original GitHub issue: https://github.com/open-webui/open-webui/issues/9404 # Bug Report open-webui version 0.5.9 Any search request starts but returns Search returns SyntaxError: Unexpected token '<', "<html> <h"... is not valid JSON Using latest docker version of open-webui Environment is Jetson AGX Orin Model used - tested with 20 models all Llama 3.1 3.2, Mistral, Nemotron Failure started as soon as open-webui was upgraded to 0.5.9 **Might be related to [[Bug]DuckDuckGo Web Search is broken #9283** ## Important Notes - **Before submitting a bug report**: Please check the Issues or Discussions section to see if a similar issue or feature request has already been posted. It's likely we're already tracking it! If you’re unsure, start a discussion post first. This will help us efficiently focus on improving the project. - **Collaborate respectfully**: We value a constructive attitude, so please be mindful of your communication. If negativity is part of your approach, our capacity to engage may be limited. We’re here to help if you’re open to learning and communicating positively. Remember, Open WebUI is a volunteer-driven project managed by a single maintainer and supported by contributors who also have full-time jobs. We appreciate your time and ask that you respect ours. - **Contributing**: If you encounter an issue, we highly encourage you to submit a pull request or fork the project. We actively work to prevent contributor burnout to maintain the quality and continuity of Open WebUI. - **Bug reproducibility**: If a bug cannot be reproduced with a `:main` or `:dev` Docker setup, or a pip install with Python 3.11, it may require additional help from the community. In such cases, we will move it to the "issues" Discussions section due to our limited resources. We encourage the community to assist with these issues. Remember, it’s not that the issue doesn’t exist; we need your help! Note: Please remove the notes above when submitting your post. Thank you for your understanding and support! --- ## Installation Method Latest docker [Describe the method you used to install the project, e.g., git clone, Docker, pip, etc.] run with: docker run -d --network=host -v open-webui:/app/backend/data -e OLLAMA_BASE_URL=http://127.0.0.1:11434 --name open-webui --restart always ghcr.io/open-webui/open-webui:cuda on the jetson Platform you have to use " --network=host" to get the networking to interface with the OS network. ## Environment - **Open WebUI Version:** [e.g., v0.3.11] - **Ollama (if applicable):** [e.g., v0.2.0, v0.1.32-rc1] - **Operating System:** [e.g., Windows 10, macOS Big Sur, Ubuntu 20.04] - **Browser (if applicable):** [e.g., Chrome 100.0, Firefox 98.0] **Confirmation:** - [x] I have read and followed all the instructions provided in the README.md. - [x] I am on the latest version of both Open WebUI and Ollama. - [ ] I have included the browser console logs. - [ ] I have included the Docker container logs. - [x] I have provided the exact steps to reproduce the bug in the "Steps to Reproduce" section below. ## Expected Behavior: the model opens a search and searches 3 websites and returns a valid response ## Actual Behavior: the model searches 3 sites and then returns the message SyntaxError: Unexpected token '<', "<html> <h"... is not valid JSON ## Description **Bug Summary:** The model searches 3 sites and then after a very long delay 10> mins, returns the message SyntaxError: Unexpected token '<', "<html> <h"... is not valid JSON ## Reproduction Details **Steps to Reproduce:** load 0.5.9 docker instance, choose any model, select websearch, and search fails. ## Logs and Screenshots **Browser Console Logs:** [Include relevant browser console logs, if applicable] **Docker Container Logs:** [Include relevant Docker container logs, if applicable] **Screenshots/Screen Recordings (if applicable):** [Attach any relevant screenshots to help illustrate the issue] ## Additional Information On the Jetson AGX Orin you can't use docker internal network run with: docker run -d --network=host -v open-webui:/app/backend/data -e OLLAMA_BASE_URL=http://127.0.0.1:11434 --name open-webui --restart always ghcr.io/open-webui/open-webui:cuda on the jetson Platform you have to use " --network=host" to get the networking to interface with the OS network. ## Note If the bug report is incomplete or does not follow the provided instructions, it may not be addressed. Please ensure that you have followed the steps outlined in the README.md and troubleshooting.md documents, and provide all necessary information for us to reproduce and address the issue. Thank you!
Author
Owner

@dht-hedaihua commented on GitHub (Feb 5, 2025):

I also encountered a similar error in the latest version 0.5.9 (docker start), where all conversations became unavailable:

SyntaxError: Unexpected token 'd', "data: {"id"... is not valid JSON
Image

However, from the console, I can see that the large language model responded to the message normally:

Image
<!-- gh-comment-id:2637328643 --> @dht-hedaihua commented on GitHub (Feb 5, 2025): I also encountered a similar error in the latest version 0.5.9 (docker start), where all conversations became unavailable: ```shell SyntaxError: Unexpected token 'd', "data: {"id"... is not valid JSON ``` <img width="1058" alt="Image" src="https://github.com/user-attachments/assets/129c4f86-0892-42c0-94eb-833a6abf5658" /> However, from the console, I can see that the large language model responded to the message normally: <img width="1611" alt="Image" src="https://github.com/user-attachments/assets/514f228c-940f-42cf-aa1c-aaebe45b08d7" />
Author
Owner

@GM020 commented on GitHub (Feb 5, 2025):

I have a similar issue - SyntaxError: Unexpected token '<', "<html>
<h"... is not valid JSON

gpt-4o and ollama work fine. But Deepseek R1 responses give this error.
Ollana and Deepseek are serverless endpoints on Azure.

<!-- gh-comment-id:2637537698 --> @GM020 commented on GitHub (Feb 5, 2025): I have a similar issue - SyntaxError: Unexpected token '<', "<html> <h"... is not valid JSON gpt-4o and ollama work fine. But Deepseek R1 responses give this error. Ollana and Deepseek are serverless endpoints on Azure.
Author
Owner

@controlaltnerd commented on GitHub (Feb 5, 2025):

I'm getting something similar with every model through any connection: SyntaxError: Unexpected token 'd', "data: {"id"... is not valid JSON. Everything was fine this morning, then I updated from 0.5.7 to 0.5.9 and now no conversations work. However, I have continue.dev in VS Code connected to my OpenWebUI instance, and chats through the API are working just fine.

<!-- gh-comment-id:2637955659 --> @controlaltnerd commented on GitHub (Feb 5, 2025): I'm getting something similar with every model through any connection: `SyntaxError: Unexpected token 'd', "data: {"id"... is not valid JSON`. Everything was fine this morning, then I updated from 0.5.7 to 0.5.9 and now no conversations work. However, I have continue.dev in VS Code connected to my OpenWebUI instance, and chats through the API are working just fine.
Author
Owner

@tjbck commented on GitHub (Feb 5, 2025):

Image

We'll need full backend logs here, unable to reproduce with chatgpt-4o + duckduckgo.

<!-- gh-comment-id:2638028328 --> @tjbck commented on GitHub (Feb 5, 2025): ![Image](https://github.com/user-attachments/assets/81be40dc-1abf-46c9-af89-aa2e3c1159c7) We'll need full backend logs here, unable to reproduce with chatgpt-4o + duckduckgo.
Author
Owner

@codecrafting-io commented on GitHub (Feb 5, 2025):

For me when using Deepseek R1 14B with duckduckgo it shows the error "'NoneType' object has no attribute 'pop'"

<!-- gh-comment-id:2638175702 --> @codecrafting-io commented on GitHub (Feb 5, 2025): For me when using Deepseek R1 14B with duckduckgo it shows the error "'NoneType' object has no attribute 'pop'"
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#15491