Support additional (Python) types in more than the type
validator
#727
Labels
Dialects v2
Issues which will likely be addressed as part of reworked dialect support
Enhancement
Some new desired functionality
In issue #364 and the related PR the type checker was expanded to allow redefining how jsonschema identifies/validates a type, with the intention of allowing a named tuple to be used as a jsonschema "object" type. In practice, this does not appear to be enough, as other portions of jsonschema use the python "in" expression to test for or iterate over properties in an object. In a NamedTuple, this will actually test the values of the properties. Two specific examples (required and additionalProperties) highlight this:
This is more of an FYI, as #364 was targeted at supporting NamedTuple, but it looks like there would be some bigger changes required to facilitate redefining how properties are identified/accessed in the NamedTuple.
The text was updated successfully, but these errors were encountered: