cadrumo.application.invoices.catalogue_reads_ports module

Application-owned read capabilities for invoice and transaction catalogues.

Core types: InvoiceCatalogue, TransactionCatalogue.

exception InvoiceCatalogueReadPersistenceError(operation)[source]

Bases: CadrumoError

Translated failure while loading a catalogue for link verification.

Parameters:

operation (str)

Return type:

None

code
class InvoiceCatalogueReader(*args, **kwargs)[source]

Bases: Protocol

Read capability for the application-facing invoice catalogue projection.

load()[source]

Return the validated invoice catalogue for the composed bucket.

Return type:

InvoiceCatalogue

class TransactionCatalogueReader(*args, **kwargs)[source]

Bases: Protocol

Read capability for the application-facing transaction projection.

load()[source]

Return the validated transaction catalogue for the composed bucket.

Return type:

TransactionCatalogue

partition_by_date_range(start, end)[source]

Return the bucket’s transactions split at the requested date window.

Return type:

LedgerDatePartition

Parameters:
class BucketBoundCatalogueReader(*args, **kwargs)[source]

Bases: Protocol

A catalogue reader backed by one profile bucket’s store.

property bucket_id: str | None

Return the bucket the reader is bound to, or None when unbound.

class InvoiceCatalogueReadPorts(invoice_reader, transaction_reader)[source]

Bases: object

Required catalogue capabilities for one composed ledger read path.

Parameters:
invoice_reader: InvoiceCatalogueReader
transaction_reader: TransactionCatalogueReader