mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-08 21:09:41 -05:00
[PR #18452] [MERGED] fix: Handle invalid order_by attribute in Chat #24797
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/18452
Author: @kaiwinut
Created: 10/20/2025
Status: ✅ Merged
Merged: 10/20/2025
Merged by: @tjbck
Base:
dev← Head:fix/chat-getattr-error📝 Commits (1)
2b0b87cfix: handle invalid order_by attribute in Chat📊 Changes
1 file changed (+1 additions, -1 deletions)
View changed files
📝
backend/open_webui/models/chats.py(+1 -1)📄 Description
Pull Request Checklist
Note to first-time contributors: Please open a discussion post in Discussions and describe your changes before submitting a pull request.
Before submitting, make sure you've checked the following:
devbranch. Not targeting thedevbranch may lead to immediate closure of the PR.Changelog Entry
Description
getattrraises anAttributeErrorwhen the provided name is not valid if no default return value is specified. This fix handles invalidorder_byattributes and prevents theAttributeErrorAdded
N/A
Changed
N/A
Deprecated
N/A
Removed
N/A
Fixed
order_byattributes correctlySecurity
N/A
Breaking Changes
N/A
Additional Information
The current implementation results in the following error (https://github.com/open-webui/open-webui/pull/18400)
Screenshots or Videos
N/A
Contributor License Agreement
By submitting this pull request, I confirm that I have read and fully agree to the Contributor License Agreement (CLA), and I am providing my contributions under its terms.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.