-
Notifications
You must be signed in to change notification settings - Fork 300
Closed
Description
As per #21 we need to make sure values are copied.
As @tiangolo points out at in pydantic/pydantic#4218 (comment) we need to be able to validate a model without relying on isinstance.
I think we should therefore change how existing models are validated to effectively revalidate model.__dict__. That should solving copying (of models at least) and avoid subclasses being validated as parent classes.
This might have some performance impact, but it'll be much smaller than a hack in python to work around it.
tiangolo
Metadata
Metadata
Assignees
Labels
No labels