[GH-ISSUE #19493] issue: Web page attachment broken in v0.6.39 and v0.6.40 - TypeError on metadata check #34429

Closed
opened 2026-04-25 08:25:27 -05:00 by GiteaMirror · 8 comments
Owner

Originally created by @mikkelnl on GitHub (Nov 25, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/19493

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

v0.6.40

Ollama Version (if applicable)

No response

Operating System

Raspberry Pi OS

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

The webpage content should be fetched and attached to the chat context.

Actual Behavior

Error message: [ERROR: argument of type 'bool' is not iterable]

Steps to Reproduce

  1. Open a chat in OpenWebUI v0.6.39 or v0.6.40
  2. Click the attachment button
  3. Select "Attach webpage"
  4. Enter any URL (e.g., https://www.wikipedia.org/)
  5. Click to attach

Logs & Screenshots

2025-11-25 20:54:43.536 | INFO | open_webui.routers.retrieval:save_docs_to_vector_db:1252 - save_docs_to_vector_db: document Wikipedia 9a9d50ec8631eafde241ce5b6991ebb9ba74c8543397179e1b589e700bedefd
2025-11-25 20:54:43.537 | ERROR | open_webui.routers.retrieval:process_web:1744 - argument of type 'bool' is not iterable
Traceback (most recent call last):
File "/app/backend/open_webui/routers/retrieval.py", line 1723, in process_web
await run_in_threadpool(
File "/usr/local/lib/python3.11/site-packages/starlette/concurrency.py", line 38, in run_in_threadpool
return await anyio.to_thread.run_sync(func)
File "/usr/local/lib/python3.11/site-packages/anyio/to_thread.py", line 56, in run_sync
return await get_async_backend().run_sync_in_worker_thread(
File "/usr/local/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 2485, in run_sync_in_worker_thread
return await future
File "/usr/local/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 976, in run
result = context.run(func, *args)
File "/app/backend/open_webui/routers/retrieval.py", line 1257, in save_docs_to_vector_db
if metadata and "hash" in metadata:
│ └ True
└ True
TypeError: argument of type 'bool' is not iterable

Additional Information

Root Cause:
The metadata parameter in save_docs_to_vector_db() receives a boolean value (True) instead of a dictionary object. The code attempts to check if the string "hash" exists in metadata, which fails because Python cannot iterate over a boolean type.

Regression Source:
This appears to be related to the embedding operation refactoring mentioned in v0.6.39 changelog:

🔍 Knowledge base reindexing now works correctly after resolving async execution chain issues by implementing threadpool workers for embedding operations. #19434

Workaround:
Downgrade to v0.6.38:

image: ghcr.io/open-webui/open-webui:0.6.38
Originally created by @mikkelnl on GitHub (Nov 25, 2025). Original GitHub issue: https://github.com/open-webui/open-webui/issues/19493 ### 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 v0.6.40 ### Ollama Version (if applicable) _No response_ ### Operating System Raspberry Pi OS ### 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 The webpage content should be fetched and attached to the chat context. ### Actual Behavior Error message: `[ERROR: argument of type 'bool' is not iterable]` ### Steps to Reproduce 1. Open a chat in OpenWebUI v0.6.39 or v0.6.40 2. Click the attachment button 3. Select "Attach webpage" 4. Enter any URL (e.g., https://www.wikipedia.org/) 5. Click to attach ### Logs & Screenshots 2025-11-25 20:54:43.536 | INFO | open_webui.routers.retrieval:save_docs_to_vector_db:1252 - save_docs_to_vector_db: document Wikipedia 9a9d50ec8631eafde241ce5b6991ebb9ba74c8543397179e1b589e700bedefd 2025-11-25 20:54:43.537 | ERROR | open_webui.routers.retrieval:process_web:1744 - argument of type 'bool' is not iterable Traceback (most recent call last): File "/app/backend/open_webui/routers/retrieval.py", line 1723, in process_web await run_in_threadpool( File "/usr/local/lib/python3.11/site-packages/starlette/concurrency.py", line 38, in run_in_threadpool return await anyio.to_thread.run_sync(func) File "/usr/local/lib/python3.11/site-packages/anyio/to_thread.py", line 56, in run_sync return await get_async_backend().run_sync_in_worker_thread( File "/usr/local/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 2485, in run_sync_in_worker_thread return await future File "/usr/local/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 976, in run result = context.run(func, *args) File "/app/backend/open_webui/routers/retrieval.py", line 1257, in save_docs_to_vector_db if metadata and "hash" in metadata: │ └ True └ True TypeError: argument of type 'bool' is not iterable ### Additional Information **Root Cause:** The `metadata` parameter in `save_docs_to_vector_db()` receives a boolean value (`True`) instead of a dictionary object. The code attempts to check if the string `"hash"` exists in `metadata`, which fails because Python cannot iterate over a boolean type. **Regression Source:** This appears to be related to the embedding operation refactoring mentioned in v0.6.39 changelog: > 🔍 Knowledge base reindexing now works correctly after resolving async execution chain issues by implementing threadpool workers for embedding operations. #19434 **Workaround:** Downgrade to v0.6.38: ```yaml image: ghcr.io/open-webui/open-webui:0.6.38
GiteaMirror added the bug label 2026-04-25 08:25:27 -05:00
Author
Owner

@kfuglsang commented on GitHub (Nov 25, 2025):

Can confirm that I get the same in v0.6.40.

<!-- gh-comment-id:3577696799 --> @kfuglsang commented on GitHub (Nov 25, 2025): Can confirm that I get the same in v0.6.40.
Author
Owner

@Classic298 commented on GitHub (Nov 25, 2025):

No this is most likely not related to that.

The PR #19434 makes a fix to the reindex function.

You are not using the reindex function, you are fetching a website

<!-- gh-comment-id:3577800716 --> @Classic298 commented on GitHub (Nov 25, 2025): No this is most likely not related to that. The PR #19434 makes a fix to the reindex function. You are not using the reindex function, you are fetching a website
Author
Owner

@Classic298 commented on GitHub (Nov 25, 2025):

Do you use the new feature that ingests additional metadata when reranking?

Please share your FULL setup and FULL embedding config and documents page and settings and steps to reproduce.

<!-- gh-comment-id:3577807245 --> @Classic298 commented on GitHub (Nov 25, 2025): Do you use the new feature that ingests additional metadata when reranking? Please share your FULL setup and FULL embedding config and documents page and settings and steps to reproduce.
Author
Owner

@tjbck commented on GitHub (Nov 25, 2025):

Likely addressed in dev, testing wanted here.

<!-- gh-comment-id:3577827657 --> @tjbck commented on GitHub (Nov 25, 2025): Likely addressed in dev, testing wanted here.
Author
Owner

@silentoplayz commented on GitHub (Nov 26, 2025):

Attaching a webpage as knowledge works fine for me on the latest dev.

Image
<!-- gh-comment-id:3578736144 --> @silentoplayz commented on GitHub (Nov 26, 2025): Attaching a webpage as knowledge works fine for me on the latest dev. <img width="2301" height="553" alt="Image" src="https://github.com/user-attachments/assets/67a02d7c-78b8-44e7-b976-41aeee0200f5" />
Author
Owner

@frenzybiscuit commented on GitHub (Nov 27, 2025):

It doesn't work fine for me. Why was this closed?

<!-- gh-comment-id:3584380796 --> @frenzybiscuit commented on GitHub (Nov 27, 2025): It doesn't work fine for me. Why was this closed?
Author
Owner

@frenzybiscuit commented on GitHub (Nov 27, 2025):

Using v0.6.40

<!-- gh-comment-id:3584381639 --> @frenzybiscuit commented on GitHub (Nov 27, 2025): Using v0.6.40
Author
Owner

@Classic298 commented on GitHub (Nov 27, 2025):

@frenzybiscuit tim wrote addressed in dev, meaning in the development version - meaning it will work in .41

<!-- gh-comment-id:3584474860 --> @Classic298 commented on GitHub (Nov 27, 2025): @frenzybiscuit tim wrote addressed in dev, meaning in the development version - meaning it will work in .41
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#34429