From ff5321da29fe6d14d998b7ee517d61731ae0b3c0 Mon Sep 17 00:00:00 2001 From: TShapinsky Date: Wed, 12 Apr 2023 16:18:49 -0600 Subject: [PATCH] unbuffered stdout so that output show up when not run in pseudo-tty --- alfalfa_bacnet_bridge/alfalfa_watchdog.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/alfalfa_bacnet_bridge/alfalfa_watchdog.py b/alfalfa_bacnet_bridge/alfalfa_watchdog.py index 5fd8239..0fe2584 100644 --- a/alfalfa_bacnet_bridge/alfalfa_watchdog.py +++ b/alfalfa_bacnet_bridge/alfalfa_watchdog.py @@ -66,7 +66,7 @@ async def main_loop(host: str, alfalfa_site: str, command: str): child_process.kill() elif child_process != None: logger.info(f"Process '{child_process.pid}' died, restarting process") - child_process = Popen(["python", command, host, site_id]) + child_process = Popen(["python", "-u", command, host, site_id]) logger.info(f"Spawned new child process: '{child_process.pid}'") old_site_id = site_id