From 88beb5883847dc37eec4a16ab6177a78bf734178 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sat, 5 Aug 2023 10:15:08 +0530 Subject: [PATCH] Prevent go test output being interleaved with python --- kitty_tests/main.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kitty_tests/main.py b/kitty_tests/main.py index ef308a173..9ff587b83 100644 --- a/kitty_tests/main.py +++ b/kitty_tests/main.py @@ -178,6 +178,8 @@ def run_python_tests(args: Any, go_proc: 'Optional[subprocess.Popen[bytes]]' = N if go_proc.wait(0.1) is None: go_proc.kill() + sys.stdout.flush() + sys.stderr.flush() print(go_proc.stdout.read().decode('utf-8', 'replace'), end='', flush=True) go_proc.stdout.close() go_proc.wait()