From 934bfe899526f308f7c46334bf021c5551ed4efb Mon Sep 17 00:00:00 2001 From: Jack Rosenthal Date: Sun, 11 Feb 2024 23:27:51 -0700 Subject: [PATCH] cli_launcher: Add encoding in quiet_run --- cli_launcher.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cli_launcher.py b/cli_launcher.py index ef06d21..8e543f6 100755 --- a/cli_launcher.py +++ b/cli_launcher.py @@ -37,7 +37,11 @@ def quiet_run(argv) -> None: """Run a command, staying quiet unless there's an error.""" try: subprocess.run( - argv, check=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT + argv, + check=True, + stdout=subprocess.PIPE, + stderr=subprocess.STDOUT, + encoding="utf-8", ) except subprocess.CalledProcessError as e: print(f"Command failed ({argv})!", file=sys.stderr)