def METHOD_NAME(self, cmdlist, infile=None):
    process = subprocess.Popen(
        cmdlist,
        stdin=infile if infile else subprocess.PIPE,
        stdout=subprocess.PIPE,
        stderr=subprocess.STDOUT,
        close_fds=True,
    )
    stdout, stderr = process.communicate()
    retcode = process.poll()
    return (retcode, stdout.decode("utf-8"))