cadrumo.application.aggregation.errors module¶
Errors raised while handling aggregation and source-mesh boundaries.
Raised by pure rollup modules such as iva_ledger,
renta_ledger, retenciones, counterpart, and
foreign_assets, and by source-mesh resolvers such as
modelo_bindings and oss_ioss, when aggregation constraints
or resolver ownership contracts are violated.
- exception AggregationConfigError(message=None, *, context=None, translated_message=None)[source]¶
Bases:
CoreErrorRaised when an aggregation service composition invariant is violated.
Its canonical registered ancestry is
CoreError, so it participates in the central error registry andbuild_error_envelope. Pydantic field and model validators translate it toValueErrorat their narrow boundary.- Parameters:
- Return type:
None
- code¶
- exception AggregationError(message, *, context=None, precondition_verdict=None)[source]¶
Bases:
TerminalPreconditionErrorMixin[PreconditionVerdict],CadrumoErrorBase class for financial transaction aggregation failures.
The
translated_messagefield is a translation key resolved by the internationalization system at runtime. The same key is also routed through the positionalmessage=arg sostr(exc)returns the key (rather than the empty string) for diagnostic surfaces, structured logs, and operator error envelopes that render exceptions viastr. Without this routing, every operator-facing display of an aggregation error showed the empty string.- Parameters:
message (tr)
precondition_verdict (PreconditionVerdict | None)
- Return type:
None
- code¶
- exception AggregationPeriodError(message, *, context=None, precondition_verdict=None)[source]¶
Bases:
AggregationErrorRaised when a requested filing period cannot be parsed unambiguously.
- Parameters:
message (tr)
precondition_verdict (PreconditionVerdict | None)
- Return type:
None
- code¶
- exception AggregationUnsupportedModeloError(message, *, context=None, precondition_verdict=None)[source]¶
Bases:
AggregationErrorRaised when no aggregation contract is available for the requested modelo.
- Parameters:
message (tr)
precondition_verdict (PreconditionVerdict | None)
- Return type:
None
- code¶
- exception AggregationMissingClassificationError(message, *, context=None, precondition_verdict=None)[source]¶
Bases:
AggregationErrorRaised when in-period transactions still need business classification.
- Parameters:
message (tr)
precondition_verdict (PreconditionVerdict | None)
- Return type:
None
- code¶
- exception AggregationCategoryCoverageError(message, *, context=None, precondition_verdict=None)[source]¶
Bases:
AggregationErrorRaised when a business transaction lacks category or profile coverage.
- Parameters:
message (tr)
precondition_verdict (PreconditionVerdict | None)
- Return type:
None
- code¶
- exception AggregationValidationError(message, *, context=None, precondition_verdict=None)[source]¶
Bases:
AggregationErrorRaised on invalid aggregation payload or state.
Its canonical registered ancestry is
AggregationErrorunder the application error registry. Pydantic field validators translate this registered failure toValueErrorat their narrow boundary.- Parameters:
message (tr)
precondition_verdict (PreconditionVerdict | None)
- Return type:
None
- code¶