Skip to content

Scrapy, a fast high-level web crawling & scraping framework for Python.

Update httpcache.py

nanolaba583e4d53130
diff --git a/scrapy/extensions/httpcache.py b/scrapy/extensions/httpcache.py
index a871cc895..247cac64e 100644
--- a/scrapy/extensions/httpcache.py
+++ b/scrapy/extensions/httpcache.py
@@ -328,7 +328,7 @@ class FilesystemCacheStorage(object):
metapath = os.path.join(rpath, 'pickled_meta')
if not os.path.exists(metapath):
return # not found
- mtime = os.stat(rpath).st_mtime
+ mtime = os.stat(metapath).st_mtime
if 0 < self.expiration_secs < time() - mtime:
return # expired
with self._open(metapath, 'rb') as f: