def reviews(project, status="open", branch="master"):
    arr = []
    cmd = 'ssh review gerrit' \
          ' query "status: %s project: openstack/%s branch: %s"' \
          ' --current-patch-set --format JSON' \
          % (status, project, branch)
    p = subprocess.Popen([cmd], shell=True, stdin=subprocess.PIPE,
                         stdout=subprocess.PIPE, stderr=subprocess.PIPE)
    stdout = p.stdout
    for line in stdout.readlines():
        review = json.loads(line)
        if review in 'project':
            arr.append(review)

    return arr
dataset/ETHPy150Open openstack-infra/reviewday/reviewday/gerrit.py/reviews/swapped operands of `in`