Ruleset schema 2: timestamp columns and period checks !4

merged merged by cmc on 2026-10-29 20:50 UTC · audit-labs/audit-report:rule-schema-v2 into main

Discussion

cmc
  • Ruleset schema: 2: a rule may declare timestamp (the column that dates each row) and max_gap_days. Schema 1 rulesets are unchanged and reject these keys; other schema numbers are refused.
  • audit_report.periods.check(rows, column, start, end, max_gap_days): rows in the period, rows dated outside it, undated rows, first and last date, and runs of more than max_gap_days days with no rows (period edges included).
  • Multi-table logic stays out of the rule schema: analytics produce ordinary tables that rules evaluate (audit-workbench roadmap 3.1).
  • Needed by audit-workbench roadmap 2.6.
  • Tests: 65 passed (4 new).