Skip to main content

Module error

Module error 

Source
Expand description

Artifact and pack-boundary error types owned by the facade. Root-owned structured errors for embedded polygon-pack loading.

§Facade role

This module is root-owned on the public facade (not a re-export from an owner crate). crate::polygonal uses it to preserve typed parser, validation, and oracle failures while loading embedded public polygon packs. Domain build errors it wraps (GridBuildError, PolygonValidationError, NavmeshValidationError, …) remain owned by their domain crates.

§Error layers

Pack loading surfaces errors at two layers:

  • ArtifactLoadError is the public load boundary: which embedded pack family failed while preserving the concrete source chain.
  • ArtifactDataError is the data/contract failure: I/O, parse, domain build, or a typed ArtifactContractError when a decoded payload violates its schema.

Prefer matching on the load-boundary family at API edges, then drill into ArtifactDataError::Contract / ArtifactContractError::kind for stable machine-readable categories without string-parsing display text.

The public loader is gated by polygonal; nested source variants also follow their domain feature requirements.

Structs§

ArtifactContractLocation
Optional position of a contract violation within a decoded artifact.

Enums§

ArtifactContractError
Typed artifact-contract failure with machine-readable identity and values.
ArtifactContractKind
Stable category for decoded artifact contract violations.
ArtifactDataError
Concrete parser, I/O, validation, or materialization failure behind a loader.
ArtifactLoadError
Public loading boundary: identifies the artifact family and preserves its source.