rialto.runner.reporting package

Submodules

rialto.runner.reporting.bookkeeper module

class rialto.runner.reporting.bookkeeper.BookKeeper(table: str, spark: SparkSession)[source]

Bases: object

Class to store and update records of runs in a table in the spark catalog.

add(record: Record) None[source]

Add a record to the table.

Parameters:

record – Record to add to the table.

rialto.runner.reporting.mailer module

class rialto.runner.reporting.mailer.Mailer[source]

Bases: object

Send email reports

static create_message(subject: str, sender: str, receiver: str, body: str) MIMEMultipart[source]

Create email message

Parameters:
  • subject – email subject

  • sender – email sender

  • receiver – email receiver

  • body – email body

static send_mail(smtp: str, message: MIMEMultipart)[source]

Send email

Parameters:
  • smtp – smtp server

  • message – email message

rialto.runner.reporting.record module

class rialto.runner.reporting.record.Record(job: str, target: str, date: ~.datetime.date, time: ~datetime.timedelta, records: int, status: str, reason: str, exception: str | None = None, run_timestamp: ~.datetime.timestamp = datetime.datetime(2025, 12, 2, 10, 4, 37, 812503))[source]

Bases: object

Dataclass with information about one run of one pipeline.

date: date
exception: str | None = None
get_schema() StructType[source]

Retrieve schema of pyspark DataFrame

job: str
reason: str
records: int
run_timestamp: timestamp = datetime.datetime(2025, 12, 2, 10, 4, 37, 812503)
status: str
target: str
time: timedelta
to_spark_row() Row[source]

Convert Record to Spark Row

rialto.runner.reporting.tracker module

class rialto.runner.reporting.tracker.Tracker(mail_cfg: MailConfig, bookkeeping: str = None, spark: SparkSession = None)[source]

Bases: object

Collect information about runs and sent them out via email

add(record: Record) None[source]

Add record for one run

report_by_mail()[source]

Create and send html report

Module contents