This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author conqp
Recipients conqp, vstinner
Date 2015-10-22.16:15:24
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1445530524.9.0.564632266909.issue25452@psf.upfronthosting.co.za>
In-reply-to
Content
A useless use case is attached.
Basically it boils down to having the ability to evaluate the CompletedProcess directly by if/else rather than comparing its returncode attribute to zero each time or handling the exception raised by check_returncode().
I use this quite frequently in programs which run system commands.
Before the new subprocess.run() method and subprocess.CompletedProcess were introduced with python 3.5 I already wrote my own library for that, wich now nearly became obsoleted by the new subprocess library of python 3.5 with the expection that it does not have this feature.
See the class ProcessResult here: https://github.com/HOMEINFO/homeinfo-lib/blob/master/homeinfo/lib/system.py
History
Date User Action Args
2015-10-22 16:15:24conqpsetrecipients: + conqp, vstinner
2015-10-22 16:15:24conqpsetmessageid: <1445530524.9.0.564632266909.issue25452@psf.upfronthosting.co.za>
2015-10-22 16:15:24conqplinkissue25452 messages
2015-10-22 16:15:24conqpcreate