From d97f98c70775c19abc9905c52cf390e1b562f3aa Mon Sep 17 00:00:00 2001 From: jonny <32085184+jonnyjohnson1@users.noreply.github.com> Date: Thu, 15 Aug 2024 17:38:37 -0500 Subject: [PATCH] removed double complete on ws_chat end --- scripts/install.sh | 2 +- topos/api/websocket_handlers.py | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/scripts/install.sh b/scripts/install.sh index 9c82f21..6e12f86 100644 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -28,6 +28,6 @@ tell application "Terminal" echo 'Nix installation complete.'; \ else \ echo 'Nix is already installed.'; \ - fi && nix-shell" + fi && nix-shell --run '$SHELL'" end tell EOF \ No newline at end of file diff --git a/topos/api/websocket_handlers.py b/topos/api/websocket_handlers.py index 4c714ae..a2ca06e 100644 --- a/topos/api/websocket_handlers.py +++ b/topos/api/websocket_handlers.py @@ -38,7 +38,6 @@ async def end_ws_process(websocket, websocket_process, process_logger, send_json # ) # await process_logger.log(log_message) # available when logger client is made await websocket.send_json(send_json) - return @router.websocket("/websocket_chat") async def chat(websocket: WebSocket): @@ -261,8 +260,7 @@ async def chat(websocket: WebSocket): if config['calculateModerationTags'] or config['calculateInMessageNER']: send_pkg['user_message'] = dummy_data send_pkg['bot_data'] = dummy_bot_data - - await websocket.send_json(send_pkg) + await end_ws_process(websocket, websocket_process, process_logger, send_pkg) except WebSocketDisconnect: