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

Make skip_on_field_errors default to True? #352

sloria opened this Issue Dec 4, 2015 · 1 comment


None yet
2 participants

sloria commented Dec 4, 2015

As a follow-up to #346, we may make skip_on_field_errors default to True.

@sloria sloria added this to the 3.0 milestone Dec 4, 2015


This comment has been minimized.


immerrr commented Dec 22, 2015

I don't think it's good to omit a check that verifies that data['x'] < data['y'] if data['foobar'] is invalid, so I'd say I'd expect @ma.validates_schema validator to run by default. However I'd expect the validator to not run by default for @ma.validates('foobar') if foobar validation failed.

Thinking it deeper, it might be better to enable the user to specify the list of pre-requisite fields validated by a certain @ma.validates_schema-validator and don't run that validator if some of the pre-requisite fields failed to validate on their own. Even better would be to have an auto-detection mechanism for such fields, but none comes to mind at this moment. And it doesn't seem that much of a user chore to "declare interest" in certain fields by adding skip_on_field_errors=['x', 'y'] when writing the validator.

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