diff --git a/template/server/messaging.py b/template/server/messaging.py index 9193445..4f537aa 100644 --- a/template/server/messaging.py +++ b/template/server/messaging.py @@ -146,6 +146,10 @@ async def change_current_directory( request = self._get_execute_request( message_id, f"Deno.chdir('{path}')", True ) + elif language == "js": + request = self._get_execute_request( + message_id, f"process.chdir('{path}')", True + ) elif language == "r": request = self._get_execute_request(message_id, f"setwd('{path}')", True) elif language == "java": @@ -216,9 +220,7 @@ async def _receive_message(self): async for message in self._ws: await self._process_message(json.loads(message)) except Exception as e: - logger.error( - f"WebSocket received error while receiving messages: {type(e)}: {str(e)}" - ) + logger.error(f"WebSocket received error while receiving messages: {str(e)}") async def _process_message(self, data: dict): """