Make sure to raise an exception if the subprocess returns a non-zero result code