Open pgleeson opened 2 years ago
I took a look at pydantic when I did the conversion to attrs/cattrs. This article gives some of the reasoning behind why I decided against using it. Overall though, both libraries implement similar functionality. The main difference between modelspec and these libraries is the non-conventional way we are representing lists of objects that have ids as dicts in JSON. Most of the code that I wrote for modelspec handles overriding default JSON serialization and deserialization of a list of objects with ids so that that ids are not serialized with other attributes in the object but instead as keys in a dictionary that contains the underlying object.
What's done here that modelspec doesn't currently do? https://github.com/pydantic/pydantic