MCPcopy
hub / github.com/colbymchenry/codegraph / runPostExtract

Method runPostExtract

src/resolution/index.ts:277–296  ·  view source on GitHub ↗

* Run each framework resolver's cross-file finalization pass and persist * the returned node updates. Idempotent — safe to call after every indexAll * and every incremental sync. Returns the number of nodes updated. * * Caches are cleared before/after so the post-extract pass sees fresh

()

Source from the content-addressed store, hash-verified

275 * state and downstream queries see the updated names.
276 */
277 runPostExtract(): number {
278 let updated = 0;
279 this.clearCaches();
280 for (const fw of this.frameworks) {
281 if (!fw.postExtract) continue;
282 try {
283 const nodes = fw.postExtract(this.context);
284 for (const node of nodes) {
285 this.queries.updateNode(node);
286 updated++;
287 }
288 } catch (err) {
289 logDebug(`Framework '${fw.name}' postExtract failed`, {
290 error: err instanceof Error ? err.message : String(err),
291 });
292 }
293 }
294 if (updated > 0) this.clearCaches();
295 return updated;
296 }
297
298 /**
299 * Pre-build lightweight caches for resolution.

Callers 2

indexAllMethod · 0.80
syncMethod · 0.80

Calls 4

clearCachesMethod · 0.95
logDebugFunction · 0.90
postExtractMethod · 0.80
updateNodeMethod · 0.80

Tested by

no test coverage detected