dc_schema
dc_schema copied to clipboard
adding additionalProperties=False to the classes schema
Thank you for this library. It is very nice to have a no-invasive solution that does not require to use a new dataclass or decorators. At the moment the exported schema do not forbid the addition of fields in the json that are not in the corresponding dataclass, which limit the capability to detect spelling errors for optional fields. It would be great to add additionalProperties=False when creating the schema for the dataclasses to make the schema more strict. I can submit a PR if that can help.
@martinResearch do you already have a solution in place? This feature would be valuable for me as well.