[GH-ISSUE #11954] issue: Google PSE - 'NoneType' object has no attribute 'encode' #16413

Closed
opened 2026-04-19 22:20:41 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @cech12 on GitHub (Mar 22, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/11954

Check Existing Issues

  • I have searched the existing issues and discussions.
  • I am using the latest version of Open WebUI.

Installation Method

Other

Open WebUI Version

v0.5.20

Ollama Version (if applicable)

No response

Operating System

Proxmox LXC container

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 listed steps to reproduce the bug in detail.

Expected Behavior

The Web Search feature with Google PSE should work.

Actual Behavior

The Web Search feature does not work with Google PSE. It shows error messages in the dialog:

Image

And no information of the search result is used in the response.

I also tried to re-download the embedding model, but it also shows errors. (see below)

Steps to Reproduce

  1. Install Open WebUI (without ollama) with the install script: https://github.com/tteck/Proxmox/blob/main/install/openwebui-install.sh
  2. (configure OpenAI Cloud models)
  3. configure Google PSE web search as descripbed here: https://docs.openwebui.com/tutorials/web-search/google-pse
  4. open a new dialog
  5. choose a model (gpt-4o-mini for example)
  6. activate web search
  7. ask about the actual date like: "search the interenet to find the actual date"
  8. see errors during search process and see the response is not correct.

Logs & Screenshots

In the service logs I could find this message:

Mar 22 13:24:06 openwebui start.sh[145]:     raise HTTPException(
Mar 22 13:24:06 openwebui start.sh[145]:           └ <class 'fastapi.exceptions.HTTPException'>
Mar 22 13:24:06 openwebui start.sh[145]: fastapi.exceptions.HTTPException: 400: [ERROR: 'NoneType' object has no attribute 'encode']

fullest log I could get: https://pastebin.com/35CMmixh

Errors when trying to download the embedding model:

Mar 22 14:49:37 openwebui start.sh[145]: RuntimeError: Failed to import transformers.integrations.integration_utils because of the following error (look up to see its traceback):
Mar 22 14:49:37 openwebui start.sh[145]: Failed to import transformers.modeling_utils because of the following error (look up to see its traceback):
Mar 22 14:49:37 openwebui start.sh[145]: libGL.so.1: cannot open shared object file: No such file or directory

https://pastebin.com/8aUyYKUS

Image

Image

Additional Information

If I activate the "Embedding and Retrieval" option, the errors don't pop up, but the search result cannot be interepreted as well

Originally created by @cech12 on GitHub (Mar 22, 2025). Original GitHub issue: https://github.com/open-webui/open-webui/issues/11954 ### Check Existing Issues - [x] I have searched the existing issues and discussions. - [x] I am using the latest version of Open WebUI. ### Installation Method Other ### Open WebUI Version v0.5.20 ### Ollama Version (if applicable) _No response_ ### Operating System Proxmox LXC container ### 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 listed steps to reproduce the bug in detail. ### Expected Behavior The Web Search feature with Google PSE should work. ### Actual Behavior The Web Search feature does not work with Google PSE. It shows error messages in the dialog: ![Image](https://github.com/user-attachments/assets/f1acd0e5-d014-491c-ba1a-c6bc1b8b91c9) And no information of the search result is used in the response. I also tried to re-download the embedding model, but it also shows errors. (see below) ### Steps to Reproduce 1. Install Open WebUI (without ollama) with the install script: https://github.com/tteck/Proxmox/blob/main/install/openwebui-install.sh 2. (configure OpenAI Cloud models) 3. configure Google PSE web search as descripbed here: https://docs.openwebui.com/tutorials/web-search/google-pse 4. open a new dialog 5. choose a model (gpt-4o-mini for example) 6. activate web search 7. ask about the actual date like: "search the interenet to find the actual date" 8. see errors during search process and see the response is not correct. ### Logs & Screenshots In the service logs I could find this message: ``` Mar 22 13:24:06 openwebui start.sh[145]: raise HTTPException( Mar 22 13:24:06 openwebui start.sh[145]: └ <class 'fastapi.exceptions.HTTPException'> Mar 22 13:24:06 openwebui start.sh[145]: fastapi.exceptions.HTTPException: 400: [ERROR: 'NoneType' object has no attribute 'encode'] ``` fullest log I could get: https://pastebin.com/35CMmixh Errors when trying to download the embedding model: ``` Mar 22 14:49:37 openwebui start.sh[145]: RuntimeError: Failed to import transformers.integrations.integration_utils because of the following error (look up to see its traceback): Mar 22 14:49:37 openwebui start.sh[145]: Failed to import transformers.modeling_utils because of the following error (look up to see its traceback): Mar 22 14:49:37 openwebui start.sh[145]: libGL.so.1: cannot open shared object file: No such file or directory ``` https://pastebin.com/8aUyYKUS ![Image](https://github.com/user-attachments/assets/ddc67e03-09c2-4818-bd85-820dbcf69d72) ![Image](https://github.com/user-attachments/assets/2e1e2f40-1281-4a48-adf1-270093190411) ### Additional Information If I activate the "Embedding and Retrieval" option, the errors don't pop up, but the search result cannot be interepreted as well
GiteaMirror added the bug label 2026-04-19 22:20:41 -05:00
Author
Owner

@Classic298 commented on GitHub (Mar 22, 2025):

Yeah that's an issue of the RAG it seems, not of the web search or google PSE.

Try installing OpenWebUI completely fresh with one of the official installation methods and not a random script that fetches the github repo.
Not sure why this script you linked to doesn't just use pip to install openwebui. That'd be the safe choice to make sure you only use pip released versions.
Make sure the script also installs all the correct dependencies that OpenWebUI demands, since it looks like the script does install other dependencies too. This might be the issue since it could install dependencies with breaking versions that OpenWebUI doesn't support.

After you did that, try to download the embedding model from the admin panel by pressing the little download button. If you do not get any errors that'd be a good sign.

And look out for all the other duplicate issues that reported RAG issues with the transformers library. I think you created a duplicate issue. You can check the existing issues for some fixes that worked for other people.

Also if you have any global settings of sorts that start python programs in an optimized mode (-OO or the equivalent environment variable) then delete that. This fixed it for me fyi.

<!-- gh-comment-id:2745349602 --> @Classic298 commented on GitHub (Mar 22, 2025): Yeah that's an issue of the RAG it seems, not of the web search or google PSE. Try installing OpenWebUI completely fresh with one of the [official installation methods](https://docs.openwebui.com/getting-started/quick-start) and not a random script that fetches the github repo. Not sure why this script you linked to doesn't just use pip to install openwebui. That'd be the safe choice to make sure you only use pip released versions. Make sure the script also installs all the correct dependencies that OpenWebUI demands, since it looks like the script does install other dependencies too. This might be the issue since it could install dependencies with breaking versions that OpenWebUI doesn't support. After you did that, try to download the embedding model from the admin panel by pressing the little download button. If you do not get any errors that'd be a good sign. And look out for all the other duplicate issues that reported RAG issues with the transformers library. I think you created a duplicate issue. You can check the existing issues for some fixes that worked for other people. Also if you have any global settings of sorts that start python programs in an optimized mode (-OO or the equivalent environment variable) then delete that. This fixed it for me fyi.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#16413