Don't show error logs on sigint (#1781)

This commit is contained in:
Nikhil Rao 2023-09-07 15:54:52 -07:00 committed by GitHub
parent 43ac87f5ca
commit 47d789e9a6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -217,7 +217,8 @@ def stream_logs(message: str, process: subprocess.Popen):
logs.append(line)
yield line
if process.returncode != 0:
# Check if the process failed (not printing the logs for SIGINT).
if process.returncode not in [0, -2]:
console.error(f"{message} failed with exit code {process.returncode}")
for line in logs:
console.error(line, end="")