Closed Tishka17 closed 2 years ago
class Book(typed_dict, total=False): name: str year: int factory = Factory() data = { "name": "hello", } raw = dict(name="hello") self.assertEqual(raw, factory.dump(data, Book))
Error:
File "/home/tishka17/src/dataclass_factory/dataclass_factory/serializers.py", line 120, in <dictcomp> data_name: serializer(getter(data, field_name)) KeyError: 'year'
Error: