Skip to content

Handle Impossible to generate slot usage entry complaints about changes in the range metadata slot #406

Closed

Description

@candleindark

Sub-issue of #389 — tracks handling Impossible to generate slot usage entry complaints about changes in the range metadata slot.

Remaining instances in dandischema/models.yaml on linkml-auto-converted:

  • Dandiset.wasGeneratedBy (parent range Activity narrowed to Project)
  • BareAsset.wasGeneratedBy (parent range narrowed in subclass)

Tasks

Activity

  1. candleindark commented on Aug 3, 2026

    @candleindark
    MemberAuthor

    This issue can be closed. Both tasks are done, on linkml-conversion.

    The wording changed, as in #407. The complaint is no longer Impossible to generate slot usage entry. After dandi/pydantic2linkml#71 allowed partial slot_usage entry generation, both instances read Cannot express in a slot_usage entry a value for the `range` .

    Fix. Both ranges are now specified explicitly through dandischema/models_merge.yaml, and the notes they made obsolete are stripped during sanitization:

    • 6c7f0e7: specify the range of Dandiset.wasGeneratedBy as Project
    • a786022: specify the range of BareAsset.wasGeneratedBy as Any, alongside its existing any_of
    • 75341f3: allow note removal to be scoped to locations in the document, so the removal targets only these two notes
    • 5b50b3c: drop the obsolete range notes on the two wasGeneratedBy slot usages

    Second task, the LinkML behavior check. tests/linkml_behavior/range_refinement/ pins both respecifications the fix depends on (narrowing a range to a subclass, and widening it to Any constrained by an any_of) against all three validators the pipeline uses: linkml-validate, gen-json-schema and gen-pydantic.

    • 5d603ae: add the range_refinement topic
    • e259d12: make the topic directories packages so sibling topics can coexist

    These run in CI under the existing LinkML behavior tests workflow (hatch run linkml-behavior-test:test).

    Result, visible on linkml-auto-converted at c17f4b5: both notes entries are gone, replaced by range: Project and range: Any. No such complaint about the range meta slot remains in the generated models.yaml.

  2. candleindark commented on Aug 3, 2026

    @candleindark
    MemberAuthor

    @yarikoptic Please take a look. Let's close this if you are OK.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions