aeat.adapters.outbound.aeat.export._errors module

Exception types for AEAT outbound export-format adapters.

The classes here cover fichero-BOE serialisation and layout failures in the outbound export adapter. They are separate from the local submission lifecycle errors in domain.submission and from the permanent live-write refusal raised by core.access_gate.

exception ExportError(message=None, *, context=None, suggestion=None, translated_message=None)[source]

Bases: AeatError

Base class for outbound AEAT export-format adapter errors.

Catch this root for failures emitted by registry-backed fichero-BOE serialisation helpers. Submission lifecycle failures remain under SubmissionError.

Parameters:
  • message (str | None)

  • context (Mapping[str, object] | None)

  • suggestion (str | None)

  • translated_message (str | None)

Return type:

None

code: ClassVar[ErrorCode]
exception AeatExportFormatError(message=None, *, context=None, suggestion=None, translated_message=None)[source]

Bases: ExportError, ValueError

Raised when a filing draft cannot be serialised to a concrete BOE format.

Inherits from ValueError to maintain compatibility with Pydantic validators and other standard library consumers that expect value-related failures.

See also

adapters.outbound.aeat.export._formats

Fixed-width record-spec, serialisation, and deserialisation helpers that raise this error for layout or value violations.

SubmissionPreflightError

Domain-level refusal raised before a local submission lifecycle transition is allowed.

Parameters:
  • message (str | None)

  • context (Mapping[str, object] | None)

  • suggestion (str | None)

  • translated_message (str | None)

Return type:

None

code: ClassVar[ErrorCode]