From 9f195af5add7c354518ca560d9588265f6b98d22 Mon Sep 17 00:00:00 2001 From: kingbri Date: Sun, 10 Dec 2023 13:28:21 -0500 Subject: [PATCH] Main: Fix function calls Some function names were declared twice. Signed-off-by: kingbri --- main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index 59de0c6..1b15154 100644 --- a/main.py +++ b/main.py @@ -166,7 +166,7 @@ async def load_model(request: Request, data: ModelLoadRequest): ) yield get_sse_packet(response.json(ensure_ascii=False)) - except CancelledError as e: + except CancelledError: print("\nError: Model load cancelled by user. Please make sure to run unload to free up resources.") except Exception as e: yield get_generator_error(str(e)) @@ -210,7 +210,7 @@ async def get_active_loras(): # Load lora endpoint @app.post("/v1/lora/load", dependencies=[Depends(check_admin_key), Depends(_check_model_container)]) -async def load_model(data: LoraLoadRequest): +async def load_lora(data: LoraLoadRequest): if not data.loras: raise HTTPException(400, "List of loras to load is not found.")