You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For a case when a validator like Or, And etc is used the ignore_extra_keys is taken as false and any extra fields cause a validation error
For example:
object {"str":"str", "extra":125} is valid for schema {"str":str} and ignore_extra_keys=true
but it is not valid for schema Or({"str":str}, None) and ignore_extra_keys=true, however, it should be valid as well
Finally, I understood I needed to set it as Or({"str":str}, None, ignore_extra_keys=true), however, it is not evident enough, so it could be more convenient if Or to use ignore_extra_keys parameter from the Scheme object
The text was updated successfully, but these errors were encountered:
For a case when a validator like Or, And etc is used the ignore_extra_keys is taken as false and any extra fields cause a validation error
For example:
object {"str":"str", "extra":125} is valid for schema {"str":str} and ignore_extra_keys=true
but it is not valid for schema Or({"str":str}, None) and ignore_extra_keys=true, however, it should be valid as well
Finally, I understood I needed to set it as Or({"str":str}, None, ignore_extra_keys=true), however, it is not evident enough, so it could be more convenient if Or to use ignore_extra_keys parameter from the Scheme object
The text was updated successfully, but these errors were encountered: