Move filter_flags to Questionnaire instance method
Report and log errors correctly

`logger` does not exist in this context. In test env we want the
exception instead of a null object. We want to report this error.