Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Diagnostic code registry

This is the canonical public registry for structured profile-zero diagnostics emitted through nuif_core::Diagnostic and for failure codes retained by the reference conformance trial. Automation must branch on code, not on the human-readable message. Messages may gain detail without changing a code.

The severity below is the default for the owning profile. A code is never repurposed; a materially different condition receives a new code. Adding a code is compatible within an alpha profile, while removing a code or changing its meaning requires a profile-version decision. entity, pointer and fidelity remain the attribution fields defined by the diagnostic record.

Transport and command failures such as malformed CLI arguments, unavailable package capabilities and WASM input limits are error classes rather than document diagnostics. Their promotion boundary is tracked separately in SDK and language-binding boundary.

cargo xtask diagnostic-audit compares this bytewise-sorted table with every code literal owned by model validation, layout evaluation and the conformance trial. It writes target/diagnostic-registry-report.json and fails when a code is undocumented, duplicated, stale, malformed or out of order.

CodeDefault severityCategoryProducerStable meaning
ASSET_RESOURCE_REQUIREDerrorassetmodel validationA portable or substituted asset lacks an exact resource digest.
ASSET_UNAVAILABLE_HAS_RESOURCEerrorassetmodel validationAn unavailable asset incorrectly binds resource bytes.
COLOR_CHANNEL_OUT_OF_RANGEerrorpaintmodel validationAn encoded-sRGB fill channel is outside the inclusive zero-to-one range.
EXTENSION_FALLBACK_NOT_USEDerrorextensionmodel validationA fallback is declared for a namespace absent from extensions_used.
EXTENSION_NAMESPACE_INVALIDerrorextensionmodel validationAn extension namespace is not a valid lowercase NUIF identifier.
EXTENSION_REQUIRED_NOT_USEDerrorextensionmodel validationA required namespace is absent from extensions_used.
EXTENSION_REQUIRED_UNSUPPORTEDwarningextensionmodel validationThe implementation preserves but does not interpret a required namespace.
EXTENSION_UNDECLAREDerrorextensionmodel validationAn attached extension namespace is absent from extensions_used.
EXTENSION_UNSUPPORTEDinformationextensionmodel validationThe implementation preserves but does not interpret a used namespace.
GRID_EXPLICIT_AREA_EXHAUSTEDerrorgridmodel validationSparse placement cannot fit another child inside the explicit grid.
GRID_PLACEMENT_OUT_OF_BOUNDSerrorgridmodel validationAn explicit grid position or span exceeds the declared tracks.
GRID_PLACEMENT_OVERLAPerrorgridmodel validationTwo children occupy an overlapping explicit grid area.
GRID_PLACEMENT_PARTIALerrorgridmodel validationA child declares only one coordinate of a required row or column pair.
GRID_PLACEMENT_WITHOUT_GRID_PARENTerrorgridmodel validationGrid placement is authored outside a direct grid child.
GRID_SPAN_INVALIDerrorgridmodel validationA grid row or column span is zero.
GRID_STYLE_WITHOUT_GRID_FAMILYerrorgridmodel validationGrid tracks or flow are authored on a non-grid container.
GRID_TRACKS_REQUIREDerrorgridmodel validationA grid container lacks an explicit row or column axis.
GRID_TRACK_INVALIDerrorgridmodel validationA fixed track size or fractional weight is not finite and positive.
GRID_TRACK_LIMIT_EXCEEDEDerrorgridmodel validationA grid axis exceeds the profile-zero track limit.
IMAGE_ASSET_INVALIDerrorimagemodel validationImage metadata has zero dimensions or an invalid decoder profile.
IMAGE_ASSET_MISSINGerrorimagemodel validationImage paint references an absent or non-image asset.
IMAGE_CROP_INVALIDerrorimagemodel validationThe crop is not a finite positive normalized rectangle inside the source.
IMAGE_PAINT_INVALIDerrorimagemodel validationImage transform, opacity or color-conversion identity is invalid.
IMAGE_PAINT_KIND_INVALIDerrorimagemodel validationImage paint is authored on an entity outside the image kind.
LAYOUT_CONSTRAINT_FALLBACKwarninglayoutlayout evaluationProfile zero evaluates a constraint family through its declared freeform fallback.
LAYOUT_FAMILY_PROFILE0_FALLBACKwarninglayoutlayout evaluationProfile zero evaluates a flex family through its declared stack fallback.
LAYOUT_UNKNOWN_KIND_FALLBACKinformationlayoutlayout evaluationAn unknown kind uses its declared container or leaf fallback geometry.
MODEL_ASSET_KEY_MISMATCHerrormodelmodel validationAn asset map key differs from the asset’s embedded identity.
MODEL_ASSET_VERSION_NOT_OPAQUEerrormodelmodel validationA newer asset schema is represented as a known rather than unknown kind.
MODEL_CHILD_MISSINGerrormodelmodel validationA child identity does not exist in the entity map.
MODEL_COMPONENT_MISSINGerrormodelmodel validationAn instance references an absent or non-component entity.
MODEL_CONTAINMENT_CYCLEerrormodelmodel validationEntity containment contains a cycle.
MODEL_DOCUMENT_VERSION_UNSUPPORTEDerrormodelmodel validationThe document schema version is newer than the implementation.
MODEL_DUPLICATE_CHILDerrormodelmodel validationOne parent lists the same child more than once.
MODEL_DUPLICATE_ROOTerrormodelmodel validationThe root list contains the same entity more than once.
MODEL_ENTITY_KEY_MISMATCHerrormodelmodel validationAn entity map key differs from the entity’s embedded identity.
MODEL_ENTITY_UNREACHABLEerrormodelmodel validationAn entity is unreachable from every root.
MODEL_ENTITY_VERSION_NOT_OPAQUEerrormodelmodel validationA newer entity schema is represented as a known rather than unknown kind.
MODEL_IDENTIFIER_INVALIDerrormodelmodel validationA semantic identifier violates the lowercase NUIF grammar.
MODEL_MULTIPLE_PARENTSerrormodelmodel validationAn entity is listed under more than one parent.
MODEL_NON_FINITE_NUMBERerrormodelmodel validationAuthored semantic state contains a non-finite number.
MODEL_RELATION_TARGET_MISSINGerrormodelmodel validationA relation endpoint is absent from the entity map.
MODEL_RESOURCE_LIMIT_EXCEEDEDerrorsecuritymodel validationThe decoded semantic document exceeds a profile-zero resource limit.
MODEL_RESPONSIVE_RANGE_INVALIDerrormodelmodel validationA responsive minimum width exceeds its maximum width.
MODEL_ROOT_HAS_PARENTerrormodelmodel validationA root entity is also listed as a child.
MODEL_ROOT_MISSINGerrormodelmodel validationA root identity does not exist in the entity map.
MODEL_TOKEN_KEY_MISMATCHerrormodelmodel validationA token map key differs from the token’s embedded identity.
MODEL_TOKEN_MISSINGerrormodelmodel validationA property references an absent token.
RESOURCE_DIGEST_INVALIDerrorresourcemodel validationAn asset resource digest is not canonical SHA-256 identity text.
SNAPSHOT_FAILEDerrorharnessconformance trialA requested trial snapshot could not be evaluated or rendered.
TEXT_FONT_BINDING_INVALIDerrortextmodel validationRequested, replacement and asset font identities are inconsistent.
TEXT_FONT_HASH_INVALIDerrortextmodel validationA text font hash is not 64 lowercase hexadecimal digits.
TEXT_FONT_NOT_PINNEDwarningtextlayout evaluationThe requested exact font is absent from the evaluation context.
TEXT_FONT_SUBSTITUTEDwarningtextlayout evaluationLayout uses an explicit replacement font present in the evaluation context.
TEXT_FONT_SUBSTITUTE_NOT_PINNEDwarningtextlayout evaluationThe declared replacement font is absent from the evaluation context.
TEXT_FONT_UNAVAILABLEwarningtextlayout evaluationThe bound font asset explicitly declares the resource unavailable.
TEXT_METRICS_INVALIDerrortextmodel validationText size or line height is not finite and positive.
TRIAL_APPLY_FAILEDerrorharnessconformance trialA generated semantic patch failed atomic application.
TRIAL_CBOR_ENCODE_FAILEDerrorharnessconformance trialThe trial document could not be encoded as deterministic CBOR.
TRIAL_CBOR_FIXPOINT_FAILEDerrorharnessconformance trialDeterministic CBOR did not reach an exact decode-encode fixpoint.
TRIAL_CHOICE_LIMIT_EXCEEDEDerrorharnessconformance trialA generated choice stream exceeded its explicit decision budget.
TRIAL_INVERSE_FAILEDerrorharnessconformance trialThe inverse of an applied patch could not be applied.
TRIAL_INVERSE_MISMATCHerrorharnessconformance trialApplying a patch and its inverse did not restore the exact base document.
TRIAL_RASTER_NONDETERMINISTICerrorharnessconformance trialRepeated CPU rasterization produced different bytes.
TRIAL_REPLAY_FAILEDerrorharnessconformance trialReplaying a generated patch from the same base failed.
TRIAL_REPLAY_HASH_MISMATCHerrorharnessconformance trialDirect application and replay produced different canonical hashes.
TRIAL_RERENDER_FAILEDerrorharnessconformance trialRepeated layout or scene construction failed.
TRIAL_SNAPSHOT_FAILEDerrorharnessconformance trialThe trial’s failure-reproduction snapshot could not be produced.
TRIAL_TEXT_ENCODE_FAILEDerrorharnessconformance trialThe trial document could not be encoded as canonical text.
TRIAL_TEXT_FIXPOINT_FAILEDerrorharnessconformance trialCanonical text did not reach an exact decode-encode fixpoint.
UNKNOWN_NAMESPACE_INVALIDerrorextensionmodel validationAn unknown kind names an invalid extension namespace.
UNKNOWN_NAMESPACE_UNDECLAREDerrorextensionmodel validationAn unknown kind names a namespace absent from extensions_used.
VALIDATION_DIAGNOSTICS_TRUNCATEDerrorsecuritymodel validationThe validator reached its retained-diagnostic limit and stopped recording ordinary issues.

Canonical source.