Codebase intelligence for AI and humans: code health scores, auto-generated docs, git analytics, dead code detection, and architectural decisions via MCP.
Python aicode-complexitycode-healthcode-intelligencecode-qualitydead-codedeveloper-toolsdocumentationgit-analyticsmcpopen-sourcepythonrefactoringstatic-analysistechnical-debt
chore(core): remove an unused decision gate shim and three unused helpers (#3883)
Raghav Chamadiyaa25eabcdd4cd
diff --git a/packages/core/src/repowise/core/analysis/decision_gate.py b/packages/core/src/repowise/core/analysis/decision_gate.pydeleted file mode 100644index e99f3d984..000000000--- a/packages/core/src/repowise/core/analysis/decision_gate.py+++ /dev/null@@ -1,8 +0,0 @@-"""Back-compat façade — moved to ``repowise.core.analysis.decisions.gate``.--Import from the new path; this re-export keeps existing imports working.-"""--from __future__ import annotations--from repowise.core.analysis.decisions.gate import * # noqa: F403diff --git a/packages/core/src/repowise/core/analysis/decisions/evolution.py b/packages/core/src/repowise/core/analysis/decisions/evolution.pyindex 226326902..96d306a5a 100644--- a/packages/core/src/repowise/core/analysis/decisions/evolution.py+++ b/packages/core/src/repowise/core/analysis/decisions/evolution.py@@ -3,7 +3,7 @@Phase 3B + 3C of the decision-layer overhaul. Two complementary mechanisms,both small and gated, both leaning on the Phase-2 primitives(:data:`decision_semantic_match.DEFAULT_DEDUP_TAU` for similarity and-:func:`decision_gate.apply_substring_gate` for anti-hallucination):+:func:`gate.apply_substring_gate` for anti-hallucination):**3B — semantic supersession & conflict** (:func:`detect_supersessions_and_conflicts`).When a freshly upserted decision is semantically *about the same topic* asdiff --git a/packages/core/src/repowise/core/analysis/decisions/extractor.py b/packages/core/src/repowise/core/analysis/decisions/extractor.pyindex b473add76..d75fb3fbd 100644--- a/packages/core/src/repowise/core/analysis/decisions/extractor.py+++ b/packages/core/src/repowise/core/analysis/decisions/extractor.py@@ -686,7 +686,7 @@ class DecisionExtractor:) -> tuple[list[ExtractedDecision], int]:"""Run the shared anti-hallucination gate over extracted decisions.- Thin wrapper around :func:`decision_gate.apply_substring_gate`, which+ Thin wrapper around :func:`gate.apply_substring_gate`, whichthe docs harvest path shares so both enforce the same grounding rules."""return apply_substring_gate(decisions)diff --git a/packages/core/src/repowise/core/analysis/health/finding_identity.py b/packages/core/src/repowise/core/analysis/health/finding_identity.pyindex 77359b302..6e3c366ea 100644--- a/packages/core/src/repowise/core/analysis/health/finding_identity.py+++ b/packages/core/src/repowise/core/analysis/health/finding_identity.py@@ -160,12 +160,6 @@ def legacy_finding_public_id(row: Any) -> str:)-def is_finding_public_id(value: str) -> bool:- """Whether a caller-supplied string has the shape this kernel mints."""- prefix, separator, digest = value.partition("_")- return bool(separator) and prefix == _PREFIX and len(digest) == 20--__all__ = ["FINDING_ID_VERSION","IDENTITY_DETAIL_KEYS",@@ -173,6 +167,5 @@ __all__ = ["SYMBOL_KEY","SYMBOL_LINE_KEY","finding_public_id",- "is_finding_public_id","legacy_finding_public_id",]diff --git a/packages/core/src/repowise/core/analysis/health/perf/facts.py b/packages/core/src/repowise/core/analysis/health/perf/facts.pyindex df3a7348c..b0cbd1182 100644--- a/packages/core/src/repowise/core/analysis/health/perf/facts.py+++ b/packages/core/src/repowise/core/analysis/health/perf/facts.py@@ -129,10 +129,6 @@ def observation_facts(row: Any) -> ObservationFacts:)-def performance_facts(rows: list[Any]) -> list[ObservationFacts]:- return [observation_facts(row) for row in rows if is_performance(row)]--def evidence_row(facts: ObservationFacts) -> dict[str, Any]:"""One public evidence entry.@@ -166,5 +162,4 @@ __all__ = ["field","is_performance","observation_facts",- "performance_facts",]diff --git a/packages/core/src/repowise/core/persistence/decision_migration.py b/packages/core/src/repowise/core/persistence/decision_migration.pyindex d0711274e..333b42367 100644--- a/packages/core/src/repowise/core/persistence/decision_migration.py+++ b/packages/core/src/repowise/core/persistence/decision_migration.py@@ -61,7 +61,6 @@ __all__ = ["backfill_decision_node_links","backfill_scope_basis","backfill_session_scope_basis",- "plan_json","plan_migration","prune_unindexed_scope_files","render_plan",@@ -690,7 +689,3 @@ def render_plan(plan: MigrationPlan, *, limit: int = 10) -> str:lines += ["", " Why records became candidates:"]lines += [f" {n:>4} {reason}" for reason, n in reasons.most_common(limit)]return "\n".join(lines)---def plan_json(plan: MigrationPlan) -> str:- return json.dumps(plan.as_dict(), indent=2)