feat(report): add dense personal report appendix
Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
@@ -43,7 +43,7 @@ TECHNIQUE_STATUSES = ("verified", "partial", "blocked")
|
||||
CONFLICT_STATUSES = ("unresolved", "partial", "resolved")
|
||||
REPORT_ACTION_PRIORITIES = ("now", "next", "watch")
|
||||
V1_CHART_IDS = ("D1", "D9", "D10")
|
||||
CHART_IDS = ("D1", "D2", "D6", "D8", "D9", "D10", "D11", "D24", "D30")
|
||||
CHART_IDS = ("D1", "D2", "D3", "D4", "D7", "D9", "D10", "D11", "D12", "D16", "D20", "D24", "D27", "D30", "D40", "D60")
|
||||
HOUSE_NUMBERS = tuple(range(1, 13))
|
||||
|
||||
FAILURE_CODES = (
|
||||
@@ -778,7 +778,14 @@ def validate_report_document(document: Any) -> ValidationResult:
|
||||
"thematicNarrative", "blockedConflictDisclosure", "evidenceAppendix", "disclaimer",
|
||||
)
|
||||
required = v1_required if version == V1_SCHEMA_VERSION else v2_required
|
||||
_check_keys(result, "(root)", document, required)
|
||||
_check_keys(result, "(root)", document, required,
|
||||
(*required, "factTables") if version == V2_SCHEMA_VERSION else required)
|
||||
if version == V2_SCHEMA_VERSION and "factTables" in document:
|
||||
try:
|
||||
from scripts.report_fact_table_contract import validate_fact_tables
|
||||
except ModuleNotFoundError:
|
||||
from report_fact_table_contract import validate_fact_tables
|
||||
validate_fact_tables(document["factTables"], result.add)
|
||||
_check_pattern(result, "reportId", document.get("reportId"), UUID_PATTERN, "uuid")
|
||||
_check_enum(result, "reportType", document.get("reportType"), REPORT_TYPES)
|
||||
_check_enum(result, "presentationMode", document.get("presentationMode"), PRESENTATION_MODES)
|
||||
|
||||
Reference in New Issue
Block a user