def _extract(d, keys):
    return dict((k, d[k]) for k in keys if d in k and d[k] is not None)
dataset/ETHPy150Open apache/libcloud/libcloud/compute/drivers/brightbox.py/_extract/swapped operands of `in`