From b77502067e21e5535f72739cd7b0188c2d78c009 Mon Sep 17 00:00:00 2001 From: Angus Whitehead Date: Thu, 3 Nov 2022 09:37:53 +0000 Subject: [PATCH] More cleanup debug --- further_link/runner/process_handler.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/further_link/runner/process_handler.py b/further_link/runner/process_handler.py index 126bd343..e7c88406 100644 --- a/further_link/runner/process_handler.py +++ b/further_link/runner/process_handler.py @@ -293,6 +293,7 @@ async def _handle_output(self, stream, channel): async def _clean_up(self): logging.debug(f"{self.id} Starting cleanup") if getattr(self, "pty", None): + logging.debug(f"{self.id} Cleaning up PTY") try: if getattr(self, "pty_master", None): await self.pty_master.close() @@ -302,12 +303,14 @@ async def _clean_up(self): logging.exception(f"{self.id} PTY Cleanup error: {e}") if getattr(self, "novnc", None): + logging.debug(f"{self.id} Cleaning up NOVNC") try: await async_stop(self.id) except Exception as e: logging.exception(f"{self.id} NOVNC Cleanup error: {e}") if getattr(self, "ipc_tasks", None): + logging.debug(f"{self.id} Cleaning up IPC") try: for channel in SERVER_IPC_CHANNELS: ipc_cleanup(channel, pgid=self.pgid) @@ -317,5 +320,6 @@ async def _clean_up(self): except Exception as e: logging.exception(f"{self.id} IPC Cleanup error: {e}") + logging.debug(f"{self.id} Releasing ID") id_generator.free(self.id) logging.debug(f"{self.id} Cleanup complete")