MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / getPendingFiles

Method getPendingFiles

src/sync/watcher.ts:1214–1225  ·  view source on GitHub ↗

* Snapshot of files seen by the watcher since the last successful sync. * * Used by MCP tool responses to mark stale results without blocking on a * sync: a tool that returns a hit in `src/foo.ts` while `src/foo.ts` is in * this list tells the agent "Read this file directly, the index la

()

Source from the content-addressed store, hash-verified

1212 * Cheap: O(pendingFiles.size), no I/O, no locks.
1213 */
1214 getPendingFiles(): PendingFile[] {
1215 const result: PendingFile[] = [];
1216 for (const [filePath, info] of this.pendingFiles) {
1217 result.push({
1218 path: filePath,
1219 firstSeenMs: info.firstSeenMs,
1220 lastSeenMs: info.lastSeenMs,
1221 indexing: this.syncing && this.syncStartedMs >= info.lastSeenMs,
1222 });
1223 }
1224 return result;
1225 }
1226}
1227
1228/**

Callers 2

withStalenessNoticeMethod · 0.45
handleStatusMethod · 0.45

Calls 1

pushMethod · 0.80

Tested by

no test coverage detected