aeat.domain.retention._errors module¶
Errors for the tax-record retention-floor domain.
RetentionFloorError is the refusal a destructive erase raises when
one or more filed tax records are still inside their legal retention window
(Ley 58/2003 art. 66/70; see
TAX_RECORD_RETENTION_FLOOR_YEARS).
- exception RetentionError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
AeatErrorBase error for the tax-record retention domain.
- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶
- exception RetentionFloorError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
RetentionErrorRaised when erasing a record still within its legal retention floor.
The Administration’s right to review a filed self-assessment prescribes four years after the voluntary filing deadline (LGT art. 66/67), and the supporting documentation must be conserved for that window (art. 70.2). Erasing such a record before the floor elapses destroys evidence the law requires kept, so the erase is refused unless the operator supplies an explicit legal-retention override.
- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶