Using a Line Chart Block in v16.4 with the Page Context setting causes an Object Reference error preventing access to the page until the block is removed.
Actual Behavior
Using a Line Chart Block in v16.4 with the Page Context setting causes an Object Reference error preventing access to the page until the block is removed.
Error produced:
Error
Object Reference not set to an instance of an object.
at Rock.Web.UI.RockPage.GetCurrentContext(EntityTypeCache entity, Dictionary`2 keyEntityDictionary) in \Rock\Web\UI\RockPage.cs:line 3116
at Rock.Reporting.Dashboard.MetricChartDashboardWidget.GetPrimaryMetricPartitionEntityIdFromContext() in \Rock\Reporting\Dashboard\MetricChartDashboardWidget.cs:line 634
at Rock.Reporting.Dashboard.MetricChartDashboardWidget.GetSelectedPartitionEntityIdentifiers() in \Rock\Reporting\Dashboard\MetricChartDashboardWidget.cs:line 555
at RockWeb.Blocks.Reporting.Dashboard.LineChartDashboardWidget.OnLoadChart()
at Rock.Reporting.Dashboard.MetricChartDashboardWidget.LoadChart() in \Rock\Reporting\Dashboard\MetricChartDashboardWidget.cs:line 769
at Rock.Reporting.Dashboard.MetricChartDashboardWidget.OnLoad(EventArgs e) in \Rock\Reporting\Dashboard\MetricChartDashboardWidget.cs:line 182
at Rock.Web.RockControlAdapter.OnLoad(EventArgs e) in \Rock\Web\RockControlAdapter.cs:line 71
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
Expected Behavior
Either a generated chart or an error that page context is required for the block to function correctly.
Steps to Reproduce
On v16.4:
On a page add a Line Chart block
Select a metric
Select "Get from page context"
Save
Issue Confirmation
[X] Perform a search on the Github Issues to see if your bug or enhancement is already reported.
[X] Try to reproduce the problem on a fresh install or on the demo site.
The workaround for this appears to be to select "Select Partition(s)" and "Combine Multiple Values". If "Combine Multiple Values" is unchecked the block will report that it has no data.
Description
Using a Line Chart Block in v16.4 with the Page Context setting causes an Object Reference error preventing access to the page until the block is removed.
Actual Behavior
Using a Line Chart Block in v16.4 with the Page Context setting causes an Object Reference error preventing access to the page until the block is removed.
Error produced:
Error Object Reference not set to an instance of an object.
Expected Behavior
Either a generated chart or an error that page context is required for the block to function correctly.
Steps to Reproduce
On v16.4:
Issue Confirmation
Rock Version
16.4
Client Culture Setting
en-Us