def cache_set(key, value, timeout=None, refreshed=False):
 if (timeout is None):
  timeout = settings.CACHE_MIDDLEWARE_SECONDS
 refresh_time = (timeout + time())
 real_timeout = (timeout + settings.CACHE_SET_DELAY_SECONDS)
 packed = (value, refresh_time, refreshed)
 return cache.set(_hashed_key(key), packed, real_timeout)

def cache_set ( key , value , timeout = None , refreshed = False ) : if ( timeout is None ) : timeout = settings . CACHE_MIDDLEWARE_SECONDS refresh_time = ( timeout + time ( ) ) real_timeout = ( timeout + settings . CACHE_SET_DELAY_SECONDS ) packed = ( value , refresh_time , refreshed ) return cache . set ( _hashed_key ( key ) , packed , real_timeout )
wrapper for cache .