Skip to content
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
Closed

Comments

@ssergiienko
Copy link

@ssergiienko 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
Copy link
Author

@ssergiienko ssergiienko commented Mar 24, 2015

a similar request from someone
#74

@nicolaiarocci
Copy link
Member

@nicolaiarocci nicolaiarocci commented Mar 25, 2015

done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants