aeat.application.wizard._errors module¶
Wizard error hierarchy.
Every wizard error inherits from AeatError so callers can
catch the package-wide base class to handle every aeat domain error
uniformly. Each concrete subclass is bound to an ErrorCode
in the application error registry.
- exception WizardError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
AeatErrorBase class for every wizard error.
- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶
- exception WizardValidationError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
WizardError,CoreValidationErrorRaised when a widget-level validator rejects an answer.
Inherits from CoreValidationError (which itself inherits from CoreError and ValueError) to participate in the shared CoreValidationError catch surface and remain compatible with pydantic field validators.
- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶
- exception WizardScriptUnderflowError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
WizardErrorRaised when a
ScriptedPrompteris asked for more answers than it carries.- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶
- exception WizardScriptOverflowError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
WizardErrorRaised when a
ScriptedPrompteris closed with unconsumed scripted answers.- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶
- exception WizardMissingFlagError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
WizardErrorRaised when a
--quietinvocation omits a required-and-not-conditional question.- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶
- exception WizardCompileError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
WizardErrorRaised when
compile_profile_keysrejects a malformed wizard catalogue.- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶
- exception WizardAnswerTypeError(message=None, *, context=None, suggestion=None, translated_message=None)[source]¶
Bases:
ProfileAnswerTypeErrorRaised when a
SetupAnswersfield coercion receives an unexpected type.Each
@field_validatorinaeat.core.setup_answers’sSetupAnswersraisesProfileAnswerTypeError(the canonical core type); this subclass is retained so application-layer code and tests that catchWizardAnswerTypeErrorby name continue to work.Inherits from
ProfileAnswerTypeError(which inherits fromCoreValidationErrorandValueError) to remain compatible with pydantic’s field-validator contract while exposing a typed exception in the error registry.- Parameters:
- Return type:
None
- code: ClassVar[ErrorCode]¶