fix: log exception when llmusage is None in finally block
This commit is contained in:
parent
4f4509641b
commit
4490021a33
@ -166,6 +166,8 @@ async def async_uapi_request(request, llm,
|
|||||||
finally:
|
finally:
|
||||||
if llmusage is not None:
|
if llmusage is not None:
|
||||||
await write_llmusage(llmusage)
|
await write_llmusage(llmusage)
|
||||||
|
else:
|
||||||
|
exception(f'llmusage is None in finally, luid={luid}, llmid={llm.id}')
|
||||||
|
|
||||||
async def modify_llmusage(ns):
|
async def modify_llmusage(ns):
|
||||||
env = ServerEnv()
|
env = ServerEnv()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user