scrapinghub / spidermon

Scrapy Extension for monitoring spiders execution.
https://spidermon.readthedocs.io
BSD 3-Clause "New" or "Revised" License
533 stars 97 forks source link

Validation monitor only raises error for first invalid field at a time #144

Closed HassanQamar07 closed 5 years ago

HassanQamar07 commented 5 years ago

The validation monitor check_missing_required_fields, check_missing_required_fields_percent, check_fields_errors and check_fields_errors_percent monitors only raises error for the first effected field because the related methods _check_missing_required_count, _check_missing_required_percent, _check_field_errors and _check_field_errors_percent is called in loop for each field and it raises error for effected field and breaks the loop for remaning fields.

https://github.com/scrapinghub/spidermon/blob/master/spidermon/contrib/monitors/mixins/validation.py#L93

muzaffaryousaf commented 5 years ago

@wRAR Please see the description of this issue.

muzaffaryousaf commented 5 years ago

@wRAR Will this be addressed under #164 as well ?

wRAR commented 5 years ago

@muzaffaryousaf yes.

wRAR commented 5 years ago

This is implemented in #164, now all errors are raised together.