mirror of
https://github.com/open-webui/open-webui.git
synced 2026-10-06 02:48:04 +00:00
fix: guard against null timings field in streaming response
Fixes #25753
This commit is contained in:
parent
b1d40f3409
commit
0057f8fb1b
1 changed files with 1 additions and 1 deletions
|
|
@ -4070,7 +4070,7 @@ async def streaming_chat_response_handler(response, ctx):
|
|||
|
||||
# Normalize usage data to standard format
|
||||
raw_usage = data.get('usage', {}) or {}
|
||||
raw_usage.update(data.get('timings', {})) # llama.cpp
|
||||
raw_usage.update(data.get('timings', {}) or {})
|
||||
if raw_usage:
|
||||
usage = normalize_usage(raw_usage)
|
||||
await event_emitter(
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue