MCPcopy Create free account
hub / github.com/ParzivalHack/PySpector / invalidate

Method invalidate

src/pyspector/ast_cache.py:287–293  ·  view source on GitHub ↗

Remove all cached data for a single file.

(self, file_path: Path)

Source from the content-addressed store, hash-verified

285 return zlib.decompress(self._get_entry(file_path, content).full_ast_json_z).decode()
286
287 def invalidate(self, file_path: Path) -> None:
288 """Remove all cached data for a single file."""
289 key = str(file_path.resolve())
290 self._l1.pop(key, None)
291 p = self._disk_path(file_path)
292 if p and p.exists():
293 p.unlink(missing_ok=True)
294
295 def get_changed_chunks(
296 self, file_path: Path, old_content: str, new_content: str

Callers 1

Calls 1

_disk_pathMethod · 0.95

Tested by 1