Skip to content

Read the catalog sidecar in the loader - #29

Merged
Simon-McIntosh merged 2 commits into
iterorganization:mainfrom
Simon-McIntosh:main
Sep 3, 2026
Merged

Read the catalog sidecar in the loader#29
Simon-McIntosh merged 2 commits into
iterorganization:mainfrom
Simon-McIntosh:main

Conversation

@Simon-McIntosh

Copy link
Copy Markdown
Collaborator

The catalog loader reads the manifest sidecar and merges each name's derived
fields into its entry before the entry union discriminates.

The reduced reviewable entry carries only name, description, documentation and
unit, which moves kind — the union's discriminator — into the sidecar. The
loader had no reference to that file, so every reduced entry failed
discrimination on the real load path with an opaque union error, even though
the model accepts the merged form.

A sidecar that is present but unparseable now raises, naming the file. Reading
it as absent would send the loader looking for an inline discriminator and hide
the real cause behind the same opaque error the fix exists to remove.

The sidecar is located beside the entries: at the repository root above them in
the standard layout, or in the entry directory itself when entries sit at the
root. A genuinely absent sidecar still loads entries that carry their own kind.

Suite: 2049 passed, 34 skipped, 82 xfailed.

The reduction moved kind, the entry union's discriminator, into the
manifest sidecar, and the loader had no reference to that file at all,
so every four-field entry failed discrimination on the real load path.
The store now reads the manifest beside the entries and merges each
name's derived fields before the union discriminates.

A present-but-unparseable manifest raises naming the file rather than
being treated as absent: returning nothing there sends the loader
looking for an inline discriminator and hides the real cause behind
the same opaque union error.

Recovered from a worker that died with the work uncommitted.
The reduction moved the entry union's discriminator into the manifest
sidecar while the loader had no reference to that file, so every
four-field entry failed discrimination on the real load path. A
present-but-unparseable sidecar now raises naming the file rather than
reading as absent, which would send the loader looking for an inline
discriminator and hide the cause behind the same opaque union error.
@Simon-McIntosh
Simon-McIntosh merged commit 488c917 into iterorganization:main Sep 3, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant