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

Catch and ignore QuestionOption.DoesNotExist #1397

Closed
oliverroick opened this issue Apr 10, 2017 · 0 comments · Fixed by #1420
Closed

Catch and ignore QuestionOption.DoesNotExist #1397

oliverroick opened this issue Apr 10, 2017 · 0 comments · Fixed by #1420

Comments

@oliverroick
Copy link
Member

oliverroick commented Apr 10, 2017

Steps to reproduce the error

  1. Create a project and upload a questionnaire that does not contain the complete list of options for standard fields. For example, use the standard questionnaire and remove one of the location type options.
  2. Go to the location detail page.

Actual behavior

Server error is thrown.

Expected behavior

The exception should be caught and ignored.

Explaination

The question options are retrieved from the database to populate translated labels for detail pages and forms. If the option was not defined in the questionnaire then the exception can be ignored, in that case, no translation will be provided for the option.

This affects several views of the platform:

  • Add location
  • Location detail
  • Edit location
  • Add relationship
  • Relationship detail
  • Relationship edit
  • Party Detail
  • Edit Party

Example exception

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

Successfully merging a pull request may close this issue.

2 participants