Skip to content

Commit

Permalink
Avoid an error in case p.stdout is None
Browse files Browse the repository at this point in the history
Co-authored-by: Bruno Oliveira <bruno@soliv.dev>
  • Loading branch information
tadeu and nicoddemus authored Jan 18, 2024
1 parent 4a985bf commit 62c44ac
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion conda_lock/invoke_conda.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,8 @@ def read_stdout() -> None:
for line in p.stderr:
stderr.append(line)
logging.error(line.rstrip())
stdout_thread.join()
if p.stdout:
stdout_thread.join()

if check_call and p.returncode != 0:
raise subprocess.CalledProcessError(
Expand Down

0 comments on commit 62c44ac

Please sign in to comment.