with requests_cache.CachedSession(cache_path, cache_control=True) as session:
fetcher = _CachingFetcher(session, timeout)
yield fetcher
if fetcher.request_count > 0:
percent = 100.0 * fetcher.cache_hit_count / fetcher.request_count
with requests_cache.CachedSession(cache_path, cache_control=True) as session:
fetcher = _CachingFetcher(session, timeout)
yield fetcher
if fetcher.request_count > 0:
percent = 100.0 * fetcher.cache_hit_count / fetcher.request_count