straight-sundown-84319
09/19/2025, 1:06 PMBaseModel instead of DiscriminatedFieldsMixin and then wondering why the schema for the model does not update with polymorphic fields...
e.g.: For a polymorphic class Animal
Bad: (The schema on this will not update as new Animals are Loaded...)
class Pack(BaseModel):
members: list[Animal]
Better but Ugly: (The schema on this will update):
class Pack(DiscriminatedFieldsMixin):
members: list[Animal]
• Using an incompatible ConfigDict - for example if you create a Polymorphic subclass with extra="allow" then I imagine that the system could get confused.