Conversation
fix: remove invalid expunge call on Pydantic FileModel Files.get_file_by_id() returns a Pydantic FileModel, not an SQLAlchemy ORM object. Calling db.expunge() on a Pydantic model fails with UnmappedInstanceError since it lacks _sa_instance_state. The expunge was also unnecessary because subsequent DB updates already use fresh sessions via get_db() context manager. Fixes #20925
…ext (#20585) Ensure chat_id is reliably passed to function pipelines/manifolds during internal task invocations (web search query generation, RAG query generation, image prompt generation). This allows stateful functions to maintain per-chat state without fragmentation, as they will now receive a consistent chat_id for all chat-scoped invocations including internal tasks. Backend changes: - Pass chat_id in generate_queries call for web search - Pass chat_id in generate_queries call for RAG/retrieval - Pass chat_id in generate_image_prompt call Frontend changes: - Add optional chat_id parameter to generateQueries API function - Add optional chat_id parameter to generateAutoCompletion API function Fixes #20563
Co-authored-by: Tim Baek <tim@openwebui.com>
* Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * docs(changelog): update CHANGELOG.md for file upload settings fix * docs: add RTL markdown table display fix to CHANGELOG * changelog: add GPU usage fix for online status indicator - Fixed high GPU usage (35-40% to near-zero) caused by animate-ping CSS animation on the user online status indicator Refs: #21062, 938d1b0 * docs(changelog): add ANSI color code fix for code execution - Fixed code execution reliability when LLMs include ANSI terminal color codes in their output - Prevents random syntax errors during code execution - Related to issue #21091 * fix: restore tool call expand/collapse functionality A refactor moved tool call display logic into a separate component but inadvertently disabled the collapsible behavior because tool calls store content in attributes rather than body text. Fixes #21205 * changelog: fix malformed Authorization header crash in Fixed section - Add entry for malformed Authorization header fix (issue #20938) The APIKeyRestrictionMiddleware now validates Authorization headers before processing them, preventing ValueError and HTTP 500 errors. * Add notification toast close button entry to CHANGELOG * Update changelog date to 2026-02-07 * fix: respect ENABLE_OLLAMA_API and ENABLE_OPENAI_API flags when url_idx is provided * Update CHANGELOG.md * Add Latvian (lv-LV) language translation * changelog: add relative time indicators for chat updates * Update CHANGELOG.md * changelog: add active chat tasks sidebar feature * changelog: Update date to 2026-02-10 and fix tool call result decoding issue (#20600) * changelog: Consolidate Open Responses protocol commits * changelog: Add Irish translations * changelog: icons, dark-mode, display * changelog: Fix dark mode icon display issue (#21272) * changelog: duplicate, icons, dark-mode * changelog: access-control-ui, sharing-users, api-groups-users * changelog: reorder access control entries for visibility * changelog: move api entry down * changelog: batch-file-ops, knowledge-base, performance * changelog: add Gboard Android clipboard fix entry * changelog: opensearch, knowledge-base, typefix * changelog: add Gboard Android fix entry * Update CHANGELOG.md * changelog: expand user sharing entry * changelog: remove emphasis word from user sharing * changelog: reformulate user sharing entry per guidelines * changelog: notifications, new-chat-fallback, device-scoped * changelog: fix embeddings endpoint batch input for Ollama * changelog: replace backticks with single quotes per style guidelines * changelog: ssl-embeddings, aiohttp-session-ssl * changelog: add Ollama auto-port fallback entry * changelog: add independent access control endpoints and permission fixes * changelog: consolidate access control entries and improve permission fix description * changelog: model selector, virtual scrolling, performance * changelog: update date to February 11, 2026 * changelog: pagination, model settings, admin * changelog: add Skill standard feature entry * changelog: add French to translations list * changelog: action-html, iframe, rich-content * changelog: tool call, html entities, multi-turn * changelog: redis model cache, performance * changelog: inline-images, context-window, fix-20916 * changelog: fix inline images context window exhaustion * changelog: audio, timeout, api * changelog: cache optimization, performance, ttft * changelog: ldap, authentication, freeze * changelog: async pipelines, event loop * changelog: streaming, connection, cleanup * changelog: add commits for Action Rich UI refactor and group performance * changelog: model access control, batch queries, database optimization * changelog: trusted-header, authentication, user-registration * changelog: add pinned read-only models entry * changelog: update date to February 12, 2026 * Update CHANGELOG.md * Update CHANGELOG.md * changelog: add issue #17058 to streaming response cleanup entry * changelog: reorder Fixed section by importance priority * Update CHANGELOG.md * changelog: add warning about chat message table migration duration * changelog: openai-api-router, model-cache-lookup, bugfix * changelog: ollama-model-name-fix, provider-compatibility * changelog: fix Ollama-compatible provider model name issue #21331 * changelog: OpenAI API endpoint detection fix * changelog: model list and import performance optimization * changelog: external tool event emitter message id support #21214 * changelog: fix large document upload worker timeout #21158 * changelog: fix RedisCluster task stopping * changelog: add discussion link to #21158 * changelog: add commit c653e4e to #21158 entry * changelog: functions, chat_id, internal_tasks * changelog: channel permissions security fix --------- Co-authored-by: Classic298 <27028174+Classic298@users.noreply.github.com@>
This reverts commit 78f9050.
# Conflicts: # .github/pull_request_template.md # backend/open_webui/config.py # backend/open_webui/functions.py # backend/open_webui/models/models.py # backend/open_webui/routers/auths.py # backend/open_webui/routers/ollama.py # backend/open_webui/routers/openai.py # backend/open_webui/utils/auth.py # backend/open_webui/utils/misc.py # package-lock.json # package.json # src/lib/i18n/locales/ar-BH/translation.json # src/lib/i18n/locales/ar/translation.json # src/lib/i18n/locales/bg-BG/translation.json # src/lib/i18n/locales/bn-BD/translation.json # src/lib/i18n/locales/bo-TB/translation.json # src/lib/i18n/locales/bs-BA/translation.json # src/lib/i18n/locales/ca-ES/translation.json # src/lib/i18n/locales/ceb-PH/translation.json # src/lib/i18n/locales/cs-CZ/translation.json # src/lib/i18n/locales/da-DK/translation.json # src/lib/i18n/locales/de-DE/translation.json # src/lib/i18n/locales/dg-DG/translation.json # src/lib/i18n/locales/el-GR/translation.json # src/lib/i18n/locales/en-GB/translation.json # src/lib/i18n/locales/en-US/translation.json # src/lib/i18n/locales/es-ES/translation.json # src/lib/i18n/locales/et-EE/translation.json # src/lib/i18n/locales/eu-ES/translation.json # src/lib/i18n/locales/fa-IR/translation.json # src/lib/i18n/locales/fi-FI/translation.json # src/lib/i18n/locales/fr-CA/translation.json # src/lib/i18n/locales/fr-FR/translation.json # src/lib/i18n/locales/gl-ES/translation.json # src/lib/i18n/locales/he-IL/translation.json # src/lib/i18n/locales/hi-IN/translation.json # src/lib/i18n/locales/hr-HR/translation.json # src/lib/i18n/locales/hu-HU/translation.json # src/lib/i18n/locales/id-ID/translation.json # src/lib/i18n/locales/ie-GA/translation.json # src/lib/i18n/locales/it-IT/translation.json # src/lib/i18n/locales/ja-JP/translation.json # src/lib/i18n/locales/ka-GE/translation.json # src/lib/i18n/locales/kab-DZ/translation.json # src/lib/i18n/locales/ko-KR/translation.json # src/lib/i18n/locales/languages.json # src/lib/i18n/locales/lt-LT/translation.json # src/lib/i18n/locales/ms-MY/translation.json # src/lib/i18n/locales/nb-NO/translation.json # src/lib/i18n/locales/nl-NL/translation.json # src/lib/i18n/locales/pa-IN/translation.json # src/lib/i18n/locales/pl-PL/translation.json # src/lib/i18n/locales/pt-BR/translation.json # src/lib/i18n/locales/pt-PT/translation.json # src/lib/i18n/locales/ro-RO/translation.json # src/lib/i18n/locales/ru-RU/translation.json # src/lib/i18n/locales/sk-SK/translation.json # src/lib/i18n/locales/sr-RS/translation.json # src/lib/i18n/locales/sv-SE/translation.json # src/lib/i18n/locales/th-TH/translation.json # src/lib/i18n/locales/tk-TM/translation.json # src/lib/i18n/locales/tr-TR/translation.json # src/lib/i18n/locales/ug-CN/translation.json # src/lib/i18n/locales/uk-UA/translation.json # src/lib/i18n/locales/ur-PK/translation.json # src/lib/i18n/locales/uz-Cyrl-UZ/translation.json # src/lib/i18n/locales/uz-Latn-Uz/translation.json # src/lib/i18n/locales/vi-VN/translation.json # src/lib/i18n/locales/zh-CN/translation.json # src/lib/i18n/locales/zh-TW/translation.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.