MCPcopy Index your code
hub / github.com/tirth8205/code-review-graph / run_post_processing

Function run_post_processing

code_review_graph/postprocessing.py:26–49  ·  view source on GitHub ↗

Run all post-build steps on a populated graph. Each step is non-fatal: failures are logged and collected as warnings so the primary build result is never lost. Args: store: An open GraphStore with nodes and edges already populated. Returns: Dict with keys for each

(store: GraphStore)

Source from the content-addressed store, hash-verified

24
25
26def run_post_processing(store: GraphStore) -> dict[str, Any]:
27 """Run all post-build steps on a populated graph.
28
29 Each step is non-fatal: failures are logged and collected as warnings
30 so the primary build result is never lost.
31
32 Args:
33 store: An open GraphStore with nodes and edges already populated.
34
35 Returns:
36 Dict with keys for each step's result count and a ``warnings``
37 list (only present when at least one step failed).
38 """
39 result: dict[str, Any] = {}
40 warnings: list[str] = []
41
42 _compute_signatures(store, result, warnings)
43 _rebuild_fts_index(store, result, warnings)
44 _trace_flows(store, result, warnings)
45 _detect_communities(store, result, warnings)
46
47 if warnings:
48 result["warnings"] = warnings
49 return result
50
51
52# -- Individual steps (private) ------------------------------------------

Calls 4

_compute_signaturesFunction · 0.85
_rebuild_fts_indexFunction · 0.85
_trace_flowsFunction · 0.85
_detect_communitiesFunction · 0.85