Fix cache file creation and validation issues - ensure cache file is properly created and handled

This commit is contained in:
Jarian Cottingham 2026-02-02 10:02:59 -06:00
parent b8228d8e07
commit 218cad82cc
2 changed files with 7 additions and 0 deletions

View File

@ -32,11 +32,13 @@ class CacheManager:
"created": datetime.now().isoformat(),
"processed_files": {}
}
# Set the cache attribute directly
self.cache = cache_data
self._save_cache()
return cache_data
except Exception as e:
logger.error(f"Error loading cache file {self.cache_file}: {e}")
logger.info("Creating new empty cache due to load error")
# Return empty cache on error
return {
"cache_version": "1.0",

View File

@ -0,0 +1,5 @@
{
"cache_version": "1.0",
"created": "2026-02-02T10:02:48.000Z",
"processed_files": {}
}