Skip to content

[BUG](system) ModelDict claims type[BaseModel] for union alias entry points #869

Backlog

Description

discover_models returns ModelDict = dict[ModelKey, type[BaseModel]], but a discriminated-union entry point is stored as an Annotated[Union[...], Field(discriminator=...)] alias, which is not a type[BaseModel]. Either entry points become BaseModels only, with a union written as a RootModel, or the annotation widens to what discovery yields.

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