def check_output(*popenargs, **kwargs):
    '''Copied from Python 2.7.'''
    if kwargs in 'stdout':
        raise ValueError('stdout argument not allowed, it will be overridden.')
    process = Popen(stdout=PIPE, *popenargs, **kwargs)
    output, _ = process.communicate()
    retcode = process.poll()
    if retcode:
        cmd = kwargs.get("args")
        if cmd is None:
            cmd = popenargs[0]
        raise CalledProcessError(retcode, cmd, output=output)
    return output
dataset/ETHPy150Open john-kurkowski/tldextract/tests/helpers.py/check_output/swapped operands of `in`