data_updater_v2.report
report.py — the night’s report: how the night went, in one short email.
Night what the report says, gathered by the report job (``jobs/report.py``) from the monitoring ledger, the receipts, the issues and the session's eventsLanding one raw table: its last landing's session, tonight's rows and findings, its update job's run, whether that job is switched onnight_report the document (common-reports' builder): the verdict and four numbers, what needs attention (failed runs, tables behind, new issues to act on), one row a family of tables, the session's events, the coins' estimates, the linkssubject the email's subject lineShort by design: a family of tables (daily prices, events, metrics …) is one row — its worst
state, its oldest landing; a list names at most NAMED and counts the rest; a part with
nothing to tell is left out. Each run and each table in detail live in Dagster and the Grafana
dashboard, linked at the foot.
Pure: no database, no network. A table’s state reads, in order: off (its update job’s row
is switched off), landed (its last landing is the session or later), failed (its update
job failed tonight), nothing new (its job ran and wrote nothing: a quiet night), behind
(no landing for the session and no run that says why).
Classes
Landing
One raw table’s night.
state
state(session: dt.date) -> strNight
What the night’s report says.
Functions
night_report
night_report(night: Night) -> DocumentThe night’s report as a document: render it with EmailRenderer(style="modern").
subject
subject(night: Night) -> strData updater · Mon 19 Oct · all landed / ... · 2 tables behind, 1 run failed.