@davoodmehraban89 / Aram / commits / b3793f2
Fork 0

fix(desktop): refuse inconsistent statement-to-reconciliation amounts in native view

davoodmehraban89 committed Oct 31, 2026 at 20:28 UTC b3793f26437bd808ab11a9e57e139b27558eda5a
1 file changed +9
backend/src/aram_backend/desktop_five_statement.py
+9
@@ -382,6 +382,15 @@ class FiveStatementWindow(tk.Tk):
382 else:
383 outcome = result
384 try:
385 + if (
386 + outcome.balance_sheet.equity_total
387 + != outcome.reconciliation.balance_sheet_equity_total
388 + or outcome.income_statement.net_result
389 + != outcome.reconciliation.income_statement_net_result
390 + or outcome.cash_flow.closing_cash_and_equivalents
391 + != outcome.reconciliation.cash_flow_closing_cash
392 + ):
393 + raise CoverageError("DESKTOP_FIGURES_SUMMARY_MISMATCH")
394 figure_rows = build_preview_figures(outcome)
395 except (CoverageError, AttributeError, TypeError, ValueError):
396 # Refuse to render unverified numeric data as a green preview.