Package list python-procrunner / af3263b
return subprocess.CompletedProcess-like object Markus Gerstel 1 year, 6 months ago
1 changed file(s) with 1 addition(s) and 16 deletion(s). Raw diff Collapse all Expand all
329329 return command
330330
331331
332 if sys.version_info < (3, 5):
333
334 class _ReturnObjectParent(object):
335 def check_returncode(self):
336 if self.returncode:
337 raise Exception(
338 "Call %r resulted in non-zero exit code %r"
339 % (self.args, self.returncode)
340 )
341
342
343 else:
344 _ReturnObjectParent = subprocess.CompletedProcess
345
346
347 class ReturnObject(dict, _ReturnObjectParent):
332 class ReturnObject(dict, subprocess.CompletedProcess):
348333 """
349334 A subprocess.CompletedProcess-like object containing the executed
350335 command, stdout and stderr (both as bytestrings), and the exitcode.