mirror of
https://github.com/open-webui/open-webui.git
synced 2026-06-05 16:28:32 -05:00
[PR #22429] [CLOSED] fix: prevent pipeline filter from corrupting chat payload on HTTP error #81559
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/22429
Author: @alvinttang
Created: 3/8/2026
Status: ❌ Closed
Base:
main← Head:fix/pipeline-filter-payload-corruption📝 Commits (1)
ff9aaa8fix: prevent pipeline filter from corrupting payload on HTTP error📊 Changes
1 file changed (+2 additions, -2 deletions)
View changed files
📝
backend/open_webui/routers/pipelines.py(+2 -2)📄 Description
Summary
In both the inlet and outlet pipeline filter processing,
response.json()was called beforeresponse.raise_for_status(). When a filter endpoint returns an HTTP error (4xx/5xx), the user's chat payload gets silently overwritten with the error response body.Impact
If a pipeline filter returns an error:
payload(containing messages, model, etc.) is replaced with the error responseexcept Exceptionhandler that just logs), the corrupted payload propagates to subsequent filters and ultimately to the chat completion endpointFix
Swapped the call order in both
process_pipeline_inlet_filterandprocess_pipeline_outlet_filter:🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.