[GH-ISSUE #20497] issue: Channel model mentions not working - 'str' object has no attribute 'app' #34729

Closed
opened 2026-04-25 08:50:31 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @jasverma-hub on GitHub (Jan 9, 2026).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/20497

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.43

Ollama Version (if applicable)

No response

Operating System

Ubuntu 22.04.5 LTS

Browser (if applicable)

Chrome

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

When mentioning a model in a channel (e.g., @gpt-4.1 hi), the model should receive the message and respond with a reply in the channel thread.

Actual Behavior

When mentioning a model in a channel, the model shows a typing indicator (●) but never responds. The error 'str' object has no attribute 'app' appears in the logs.

The issue is caused by:

  1. The request object becoming invalid in background tasks after HTTP response is sent
  2. Missing request parameter in update_message_by_id calls within model_response_handler function

Error log: 'str' object has no attribute 'app'
Full traceback: Traceback (most recent call last):
File "/app/backend/open_webui/routers/channels.py", line 1037, in model_response_handler
await update_message_by_id(
File "/app/backend/open_webui/routers/channels.py", line 1441, in update_message_by_id
check_channels_access(request)
File "/app/backend/open_webui/routers/channels.py", line 89, in check_channels_access
if not request.app.state.config.ENABLE_CHANNELS:
AttributeError: 'str' object has no attribute 'app'

Steps to Reproduce

  1. Deploy OpenWebUI using Docker with the following environment variables:

    • ENABLE_CHANNELS=true
    • ENABLE_PIPELINES=true
  2. Configure a model connection (e.g., Azure OpenAI, OpenAI, or Ollama)

  3. Log in to OpenWebUI as an admin user

  4. Create a new channel or use an existing channel

  5. In the channel, mention a model by typing: @gpt-4.1 hi (or any configured model)

  6. Observe: The model shows a typing indicator (●) but never responds

  7. Check the container logs:
    docker logs openwebui --tail 100

  8. You will see the error: 'str' object has no attribute 'app'

Configuration used:

  • Docker deployment
  • Azure OpenAI backend with Pipelines
  • ENABLE_CHANNELS=true
  • ENABLE_PIPELINES=true

Logs & Screenshots

Image azureuser@openwebui-vm:/opt/docker/openwebui$ # After testing, check logs docker logs openwebui --tail 100 | grep -A 30 "Error in model_response_handler" 2026-01-09 05:28:13.969 | ERROR | open_webui.routers.channels:model_response_ handler:1066 - Error in model_response_handler: 'str' object has no attribute 'a pp' 2026-01-09 05:28:13.969 | ERROR | open_webui.routers.channels:model_response_ handler:1067 - Traceback (most recent call last): File "/app/backend/open_webui/routers/channels.py", line 1037, in model_respon se_handler await update_message_by_id( File "/app/backend/open_webui/routers/channels.py", line 1441, in update_messa ge_by_id check_channels_access(request) File "/app/backend/open_webui/routers/channels.py", line 89, in check_channels _access if not request.app.state.config.ENABLE_CHANNELS: ^^^^^^^^^^^ AttributeError: 'str' object has no attribute 'app' 2026-01-09 05:28:14.714 | INFO | uvicorn.protocols.http.httptools_impl:send: 476 - 106.222.204.135:0 - "GET /api/v1/channels/f6d7c9e3-f4de-4be7-a507-e289370c 1d9a/messages/4919db13-63b3-4f26-8b9f-1be4eccec707/thread?skip=0&limit=50 HTTP/1 .1" 200 2026-01-09 05:28:14.949 | INFO | uvicorn.protocols.http.httptools_impl:send: 476 - 106.222.204.135:0 - "GET /api/v1/users/dd967870-a262-4e09-b83a-9d5b1938921 5 HTTP/1.1" 200 2026-01-09 05:28:14.952 | INFO | uvicorn.protocols.http.httptools_impl:send: 476 - 106.222.204.135:0 - "GET /api/v1/models/model/profile/image?id=gpt-4.1 HTT P/1.1" 200 azureuser@openwebui-vm:/opt/docker/openwebui$

Additional Information

No response

Originally created by @jasverma-hub on GitHub (Jan 9, 2026). Original GitHub issue: https://github.com/open-webui/open-webui/issues/20497 ### 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.43 ### Ollama Version (if applicable) _No response_ ### Operating System Ubuntu 22.04.5 LTS ### Browser (if applicable) Chrome ### 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 When mentioning a model in a channel (e.g., `@gpt-4.1 hi`), the model should receive the message and respond with a reply in the channel thread. ### Actual Behavior When mentioning a model in a channel, the model shows a typing indicator (●) but never responds. The error `'str' object has no attribute 'app'` appears in the logs. The issue is caused by: 1. The `request` object becoming invalid in background tasks after HTTP response is sent 2. Missing `request` parameter in `update_message_by_id` calls within `model_response_handler` function Error log: 'str' object has no attribute 'app' Full traceback: Traceback (most recent call last): File "/app/backend/open_webui/routers/channels.py", line 1037, in model_response_handler await update_message_by_id( File "/app/backend/open_webui/routers/channels.py", line 1441, in update_message_by_id check_channels_access(request) File "/app/backend/open_webui/routers/channels.py", line 89, in check_channels_access if not request.app.state.config.ENABLE_CHANNELS: AttributeError: 'str' object has no attribute 'app' ### Steps to Reproduce 1. Deploy OpenWebUI using Docker with the following environment variables: - ENABLE_CHANNELS=true - ENABLE_PIPELINES=true 2. Configure a model connection (e.g., Azure OpenAI, OpenAI, or Ollama) 3. Log in to OpenWebUI as an admin user 4. Create a new channel or use an existing channel 5. In the channel, mention a model by typing: @gpt-4.1 hi (or any configured model) 6. Observe: The model shows a typing indicator (●) but never responds 7. Check the container logs: docker logs openwebui --tail 100 8. You will see the error: 'str' object has no attribute 'app' Configuration used: - Docker deployment - Azure OpenAI backend with Pipelines - ENABLE_CHANNELS=true - ENABLE_PIPELINES=true ### Logs & Screenshots <img width="854" height="494" alt="Image" src="https://github.com/user-attachments/assets/9174d1e8-dfe4-474f-9485-d8857a18dc30" /> azureuser@openwebui-vm:/opt/docker/openwebui$ # After testing, check logs docker logs openwebui --tail 100 | grep -A 30 "Error in model_response_handler" 2026-01-09 05:28:13.969 | ERROR | open_webui.routers.channels:model_response_ handler:1066 - Error in model_response_handler: 'str' object has no attribute 'a pp' 2026-01-09 05:28:13.969 | ERROR | open_webui.routers.channels:model_response_ handler:1067 - Traceback (most recent call last): File "/app/backend/open_webui/routers/channels.py", line 1037, in model_respon se_handler await update_message_by_id( File "/app/backend/open_webui/routers/channels.py", line 1441, in update_messa ge_by_id check_channels_access(request) File "/app/backend/open_webui/routers/channels.py", line 89, in check_channels _access if not request.app.state.config.ENABLE_CHANNELS: ^^^^^^^^^^^ AttributeError: 'str' object has no attribute 'app' 2026-01-09 05:28:14.714 | INFO | uvicorn.protocols.http.httptools_impl:send: 476 - 106.222.204.135:0 - "GET /api/v1/channels/f6d7c9e3-f4de-4be7-a507-e289370c 1d9a/messages/4919db13-63b3-4f26-8b9f-1be4eccec707/thread?skip=0&limit=50 HTTP/1 .1" 200 2026-01-09 05:28:14.949 | INFO | uvicorn.protocols.http.httptools_impl:send: 476 - 106.222.204.135:0 - "GET /api/v1/users/dd967870-a262-4e09-b83a-9d5b1938921 5 HTTP/1.1" 200 2026-01-09 05:28:14.952 | INFO | uvicorn.protocols.http.httptools_impl:send: 476 - 106.222.204.135:0 - "GET /api/v1/models/model/profile/image?id=gpt-4.1 HTT P/1.1" 200 azureuser@openwebui-vm:/opt/docker/openwebui$ ### Additional Information _No response_
GiteaMirror added the bug label 2026-04-25 08:50:31 -05:00
Author
Owner

@owui-terminator[bot] commented on GitHub (Jan 9, 2026):

🔍 Similar Issues Found

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

  1. #20157 issue: Channels: Model @ mention fails with "'str' object has no attribute 'app'"
    by sheldonbob • Dec 24, 2025 • bug

  2. #19103 issue: no response from the model when ask in "channels"
    by silenceroom • Nov 11, 2025 • bug

  3. #20150 issue: Tools not included for models in channel messages
    by zhiweit • Dec 24, 2025 • bug


💡 Tips:

  • If this is a duplicate, please consider closing this issue and adding any additional details to the existing one
  • If you found a solution in any of these issues, please share it here to help others

This comment was generated automatically by a bot. Please react with a 👍 if this comment was helpful, or a 👎 if it was not.

<!-- gh-comment-id:3727375943 --> @owui-terminator[bot] commented on GitHub (Jan 9, 2026): 🔍 **Similar Issues Found** I found some existing issues that might be related to this one. Please check if any of these are duplicates or contain helpful solutions: 1. [#20157](https://github.com/open-webui/open-webui/issues/20157) **issue: Channels: Model @ mention fails with "'str' object has no attribute 'app'"** *by sheldonbob • Dec 24, 2025 • `bug`* 2. [#19103](https://github.com/open-webui/open-webui/issues/19103) **issue: no response from the model when ask in "channels"** *by silenceroom • Nov 11, 2025 • `bug`* 3. [#20150](https://github.com/open-webui/open-webui/issues/20150) **issue: Tools not included for models in channel messages** *by zhiweit • Dec 24, 2025 • `bug`* --- 💡 **Tips:** - If this is a duplicate, please consider closing this issue and adding any additional details to the existing one - If you found a solution in any of these issues, please share it here to help others *This comment was generated automatically by a bot.* Please react with a 👍 if this comment was helpful, or a 👎 if it was not.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#34729