@davoodmehraban89 / Aram / commits / ef5a282
Fork 0

fix(statements): fail closed on non-string classification values

davoodmehraban89 committed Oct 31, 2026 at 00:34 UTC ef5a2821543471c55e9fb95657de6391f9f88dfe
1 file changed +1 -1
backend/src/aram_backend/balance_sheet_candidate.py
+1 -1
@@ -103,7 +103,7 @@ def _policies(
103 _required_text(policy.subnote_code, "SUBNOTE", blank_ok=True)
104 _required_text(policy.line_label, "LABEL")
105 _required_text(policy.policy_evidence_ref, "EVIDENCE")
106 - if policy.category not in CATEGORIES:
106 + if not isinstance(policy.category, str) or policy.category not in CATEGORIES:
107 raise CoverageError("INVALID_PRESENTATION_CATEGORY")
108 if type(policy.sign_multiplier) is not int or policy.sign_multiplier not in {-1, 1}:
109 raise CoverageError("INVALID_PRESENTATION_SIGN")