class weboob.browser.cache.CacheMixin(*args, **kwargs)

Bases: object

Mixin to inherit in a Browser

cache = None

Cache store object

To limit the size of the cache, a weboob.tools.lrudict.LimitedLRUDict instance can be used.

is_updatable = None

Whether the cache is updatable

If False, once a request has been successfully executed, its response will always be returned.

If True, the ETag and Last-Modified of the response will be stored along with the cache. When the request is re-executed, instead of simply returning the previous response, the server is queried to check if a newer version of the page exists. If a newer page exists, it is returned instead and overwrites the obsolete page in the cache.


Make a key for the cache corresponding to the request.

open_with_cache(url, **kwargs)

Perform a request using the cache if possible.