mirror of
https://github.com/chubin/cheat.sh.git
synced 2024-11-22 01:40:48 +03:00
Fix cache invalidation (#324)
This commit is contained in:
parent
5671e7d0d9
commit
e66382cb53
10
lib/fetch.py
10
lib/fetch.py
@ -58,8 +58,8 @@ def fetch_all(skip_existing=True):
|
||||
sys.stdout.flush()
|
||||
try:
|
||||
process = subprocess.Popen(
|
||||
cmd, stdout=subprocess.PIPE, stderr=subprocess.STDOUT,
|
||||
universal_newlines=True)
|
||||
cmd, stdout=subprocess.PIPE, stderr=subprocess.STDOUT,
|
||||
universal_newlines=True)
|
||||
except OSError:
|
||||
print("\nERROR: %s" % cmd)
|
||||
raise
|
||||
@ -149,9 +149,11 @@ def _update_adapter(adptr):
|
||||
if entries:
|
||||
_log("%s Entries to be updated: %s", adptr, len(entries))
|
||||
|
||||
name = adptr.name()
|
||||
for entry in entries:
|
||||
_log("+ ivalidating %s", entry)
|
||||
cache.delete(entry)
|
||||
cache_name = name + ":" + entry
|
||||
_log("+ invalidating %s", cache_name)
|
||||
cache.delete(cache_name)
|
||||
|
||||
if entries:
|
||||
_log("Done")
|
||||
|
Loading…
Reference in New Issue
Block a user