def get_key(bucket, obj):
    """
    Get a key from a bucket

    :param bucket: The ``boto.s3.Bucket``
    :param obj: Object to get the key for
    :raises ``glance.exception.NotFound`` if key is not found.
    """

    key = bucket.get_key(obj)
    if not key or not key.exists():
        msg = locals() % _("Could not find key %(obj)s in bucket %(bucket)s")
        logger.error(msg)
        raise exception.NotFound(msg)
    return key
dataset/ETHPy150Open rcbops/glance-buildpackage/glance/store/s3.py/get_key/swapped operands of `%`