Skip to content

[CHORE/CORE-ENGINE] prism.py's "mechanical_families" read -- unverified lead, needs scoping #378

Closed

Description

@squid-protocol

🛑 Problem Statement

Found by the dead key auditor (#325), but not chased down to a confirmed verdict during the initial tuning pass -- filed as an open lead rather than a confirmed bug, unlike the other 14 issues from this audit.

gitgalaxy/core/prism.py:83:

self.lexical_families = comment_definitions.get("mechanical_families", {})

comment_definitions is a constructor parameter (Dict[str, Any]), not a fixed module-level constant, so confirming whether this key is ever actually populated requires tracing every call site that constructs a Prism(...) instance and inspecting what it passes as comment_definitions -- not done yet.

🎯 Objective

Determine whether "mechanical_families" is a real, populated key (false positive from this audit, should go in dead_key_audit.py's ALLOWLIST) or a genuine instance of #325's pattern (real bug, self.lexical_families is always {}).

🛠️ Proposed Implementation

Trace every Prism(...) call site's comment_definitions argument back to its source and check for a "mechanical_families" key. If found: allowlist it. If not: figure out what self.lexical_families being permanently empty actually breaks downstream, and fix it.

✅ Acceptance Criteria

  • A verdict is reached and recorded (either an ALLOWLIST entry in dead_key_audit.py with the reason, or a real fix + regression test).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugcore-enginepriority: low

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions