Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(182)

Unified Diff: client/isolateserver.py

Issue 2409103003: LRUDict: add timestamps (Closed)
Patch Set: fix test Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | client/tests/isolateserver_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/isolateserver.py
diff --git a/client/isolateserver.py b/client/isolateserver.py
index 8a8bed6763c2ba98dbe89e007a77131fd99fedd8..253d330f694a76463adeaa4084e8070d7b659bbf 100755
--- a/client/isolateserver.py
+++ b/client/isolateserver.py
@@ -1754,12 +1754,12 @@ class DiskCache(LocalCache):
"""Removes the lastest recently used file and returns its size."""
self._lock.assert_locked()
try:
- digest, size = self._lru.get_oldest()
+ digest, (size, _) = self._lru.get_oldest()
if not allow_protected and digest == self._protected:
raise Error('Not enough space to map the whole isolated tree')
except KeyError:
raise Error('Nothing to remove')
- digest, size = self._lru.pop_oldest()
+ digest, (size, _) = self._lru.pop_oldest()
logging.debug("Removing LRU file %s", digest)
self._delete_file(digest, size)
return size
« no previous file with comments | « no previous file | client/tests/isolateserver_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698