Accrue.PDF.RenderFailed exception (accrue v0.2.0)

Copy Markdown View Source

Raised from Accrue.Workers.Mailer.perform/1 when Accrue.Billing.render_invoice_pdf/2 returns a non-terminal {:error, reason} (i.e., not %Accrue.Error.PdfDisabled{} and not :chromic_pdf_not_started). Raising this exception lets Oban backoff handle transient render failures — the mailer job is retried per its max_attempts setting.

Terminal errors (Null adapter + missing ChromicPDF supervisor child) are NOT wrapped in this exception — they route to the hosted-invoice URL fallback instead of attaching a PDF.

Summary

Types

t()

@type t() :: %Accrue.PDF.RenderFailed{
  __exception__: true,
  message: term(),
  reason: term()
}