How do I retrieve the exit code when using Python’s subprocess
module and the communicate()
method?
Relevant code:
import subprocess as sp
data = sp.Popen(openRTSP + opts.split(), stdout=sp.PIPE).communicate()[0]
Should I be doing this another way?