Example #1
0
def get_temp_hostname(nonce):
    key = REDIS_HOSTNAME_KEY(nonce=nonce)
    value = redis_store.get(key)
    if value is None:
        raise KeyError("no temp_hostname stored.")
    redis_store.delete(key)
    values = value.split(',')
    if len(values) != 2:
        raise ValueError("temp_hostname value is invalid: " + value)
    else:
        return values
Example #2
0
def get_temp_hostname(nonce):
    key = REDIS_HOSTNAME_KEY(nonce=nonce)
    value = redis_store.get(key)
    if value is None:
        raise KeyError("no temp_hostname stored.")
    redis_store.delete(key)
    values = value.split(',')
    if len(values) != 2:
        raise ValueError("temp_hostname value is invalid: " + value)
    else:
        return values
Example #3
0
def get_temp_hostname(nonce):
    key = REDIS_HOSTNAME_KEY(nonce=nonce)
    value = redis_store.get(key)
    if value == None: raise KeyError()
    redis_store.delete(key)
    return value.split(',')