New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Propose: allow_unknown should be configurable separately per each scheme like #75

Closed
ssergiienko opened this Issue Mar 24, 2015 · 2 comments

Comments

Projects
None yet
2 participants
@ssergiienko
Copy link

ssergiienko commented Mar 24, 2015

Something like this:

schema = {
    'a_dict': {
        'type': 'dict',
        'allowed_unknown': True,
        'schema': {
            'address': {'type': 'string'},
            'city': {'type': 'string', 'required': True}
        }
    }
}

Why? Our use case:
We write validation of big json with mixed data. Some parts of this structure are the REST response from the external service which is under active development and often change data format, other parts is our data (they more or less stable). It's very handy to disable/enable "allowed_unknown" for some parts of this struct during "step by step" api stabilization.

@ssergiienko

This comment has been minimized.

Copy link

ssergiienko commented Mar 24, 2015

a similar request from someone
#74

@nicolaiarocci

This comment has been minimized.

Copy link
Member

nicolaiarocci commented Mar 25, 2015

done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment