mirror of
https://github.com/glomatico/gamdl.git
synced 2026-06-13 04:05:14 +03:00
Stringify subprocess args in error message
This commit is contained in:
+3
-1
@@ -20,7 +20,9 @@ async def async_subprocess(*args: str, silent: bool = False) -> None:
|
||||
stdout, stderr = await proc.communicate()
|
||||
|
||||
if proc.returncode != 0:
|
||||
msg = f"Exited with code {proc.returncode}: {' '.join(args)}"
|
||||
msg = (
|
||||
f"Exited with code {proc.returncode}: {' '.join(str(arg) for arg in args)}"
|
||||
)
|
||||
|
||||
if stdout:
|
||||
msg += f"\nstdout:\n{stdout.decode()}"
|
||||
|
||||
Reference in New Issue
Block a user