Post

We have a new release (v0.5.0) that lifts the dev.idiolect.* record set into a first-class RecordFamily abstraction and parameterizes workspace boundaries over it. The indexer, handlers, observer, and orchestrator are all generic over a record family now.

github.comRelease v0.5.0 · idiolect-dev/idiolectAdded idiolect_records::family::RecordFamily trait. Every record-set scoped boundary in the workspace (indexer, handlers, soon orchestrator + verify) parameterises over a family rather than hardco...

RecordFamily is a trait with a contains predicate over NSIDs, a decoder into the family's AnyRecord, and a serializer back. IdiolectFamily implements it for dev.idiolect.* via the codegen-emitted family module. Adding a record remains a one-file lexicon change.

OrFamily<F1, F2> composes two families into one that recognizes every NSID either side contains. Its AnyRecord is OrAny, which is a tagged union over the two halves.

drive_indexer is generic over families now. The default type parameter is IdiolectFamily, so callers can keep using drive_idiolect_indexer with no type arguments.

Out-of-family commits drop silently before decode, so an upstream PDS adding a record type ahead of codegen no longer halts the loop.

A contains-true plus decode-None mismatch is a family-implementation bug, not a data bug, so the indexer surfaces it as a dedicated IndexerError::FamilyContract variant rather than a generic handler error. This should be easier to debug and easier to reason about at the boundary.

0 reposts0 likes

No replies yet.