Function
writeCachedCodexResults
(
filePath: string,
project: string,
calls: ParsedProviderCall[],
fingerprint: FileFingerprint,
)
Source from the content-addressed store, hash-verified
| 94 | } |
| 95 | |
| 96 | export async function writeCachedCodexResults( |
| 97 | filePath: string, |
| 98 | project: string, |
| 99 | calls: ParsedProviderCall[], |
| 100 | fingerprint: FileFingerprint, |
| 101 | ): Promise<void> { |
| 102 | try { |
| 103 | const cache = await loadCache() |
| 104 | cache.files[filePath] = { |
| 105 | mtimeMs: fingerprint.mtimeMs, |
| 106 | sizeBytes: fingerprint.sizeBytes, |
| 107 | project, |
| 108 | calls, |
| 109 | } |
| 110 | } catch {} |
| 111 | } |
| 112 | |
| 113 | export async function flushCodexCache(): Promise<void> { |
| 114 | if (!memCache) return |
Tested by
no test coverage detected