Insights "error gathering the chart data" for certain projects
Summary
For certain projects, the Insights feature errors on every chart with the message: "There was an error gathering the chart data". This is due to a 500 response produced by Projects::InsightsController#query, as a result of "NoMethodError: undefined method `group_by' for nil:NilClass". See the Sentry report.
Steps to reproduce
- Go to https://gitlab.com/gitlab-org/uxr_insights/insights/#/bugClassification
- See the error message "There was an error gathering the chart data"
- Note that this doesn't happen with gitlab project Insights
What is the current bug behavior?
For certain projects, the Insights feature displays an error message and no charts.
What is the expected correct behavior?
For all projects, the Insights feature displays no error messages and all charts, as with gitlab project Insights.
Relevant logs and/or screenshots
Output of checks
This bug happens on GitLab.com.
Possible fixes
Apparently issuables
can be nil
in CountPerPeriodReducer
, which should not be possible.