aeat.application.review._errors module

Error hierarchy for the unified review queue.

All review-layer errors inherit from ReviewError, which in turn inherits from aeat.core.errors.AeatError per the project’s package-wide error-base mandate. Callers can therefore catch either ReviewError for review-specific failures or the package-wide aeat.core.errors.AeatError to handle every aeat domain error uniformly.

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

Bases: AeatError

Base class for every error raised by aeat.application.review.

Parameters:
  • message (str | None)

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

  • suggestion (str | None)

  • translated_message (str | None)

Return type:

None

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

Bases: ReviewError

Raised when a source disk file is present but cannot be parsed.

Parameters:
  • message (str | None)

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

  • suggestion (str | None)

  • translated_message (str | None)

Return type:

None

code: ClassVar[ErrorCode]
exception FilterParseError(raw_token, *, reason)[source]

Bases: ReviewError

Raised when --filter KEY=VALUE cannot be parsed.

Carries the raw token plus a stable reason code so the CLI can render a per-language repair hint.

Variables:
  • raw_token – The string the operator supplied (e.g. "status=" or "period: 1T"). Stored as an internal diagnostic attribute, but omitted from rendered messages and context because filter values may include free-text search strings or imported identifiers.

  • safe_token – A redacted token that preserves the key when it is parseable and replaces the value with <redacted>.

  • reason – One of "missing-equals", "empty-key", "empty-value", "unknown-key-{scope}", "invalid-value-{scope}", "duplicate-key-{scope}".

Parameters:
  • raw_token (str)

  • reason (str)

Return type:

None

code: ClassVar[ErrorCode]
exception EditParseError(raw_token, *, reason)[source]

Bases: ReviewError

Raised when --set KEY=VALUE cannot be parsed.

Variables:
  • raw_token – The string the operator supplied. Stored for callers that need to build a CLI recovery hint, but intentionally omitted from the rendered error text and structured context because edit values may contain file paths, references, or operator notes.

  • reason – One of "missing-equals", "empty-key", "empty-value", "unknown-key-{scope}", "invalid-value-{scope}", "duplicate-key-{scope}".

Parameters:
  • raw_token (str)

  • reason (str)

Return type:

None

code: ClassVar[ErrorCode]
exception ReviewKindReservedError(token, reason)[source]

Bases: ReviewError

Raised when the CLI receives a reserved kind token.

Carries the blocking reason returned by aeat.application.review._enums.reserved_kind_reason().

Variables:
  • token – The --kind value supplied by the user. Stored as an internal diagnostic attribute, but omitted from rendered messages and structured context because selector values are operator input and may contain copied identifiers.

  • reason – Explanation naming the blocking upstream record type.

Parameters:
Return type:

None

code: ClassVar[ErrorCode]