New submission from Noah <nlev...@archive.org>:

Suggesting option to raise exception if process exits nonzero in `with 
subprocess.Popen(...):`

with subprocess.Popen('/bin/false'):
    pass

I made the mistake of assuming this construct would raise an exception 
(CalledProcessError). It would be nice if there were a way to do that.

----------
components: Library (Lib)
messages: 344880
nosy: nlevitt
priority: normal
severity: normal
status: open
title: suggesting option to raise exception if process exits nonzero in `with 
subprocess.Popen(...):`
type: behavior

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue37184>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to