@tsteur opened this Issue on January 7th 2023 Member

Getting fatal error see details below

Error: {"message":"Impossible to invoke a method (\"getRows\") on a boolean variable (\"\").","file":"\/plugins\/CoreVisualizations\/templates\/_dataTableViz_htmlTable.twig","line":23,"request_id":"fb2d5","backtrace":" on \/plugins\/CoreVisualizations\/templates\/_dataTableViz_htmlTable.twig(23)\n#0 \/tmp\/templates_c\/a2\/a29dbd96da7e6760f554c05ce3805807dcf5299f43a7961caa864ace7b911715.php(86): twig_get_attribute(Object(Twig\Environment), Object(Twig\Source), false, 'getRows', Array, 'method', false, false, false, 23)\n#1 \/vendor\/twig\/twig\/src\/Template.php(394): TwigTemplate_48555e24c74f40810f5eeb59627fca3b4fb07d0f1207a4357d503e89e171bc34->doDisplay(Array, Array)\n#2 \/vendor\/twig\/twig\/src\/Template.php(367): Twig\Template->displayWithErrorHandling(Array, Array)\n#3 \/tmp\/templates_c\/a2\/a29dbd96da7e6760f554c05ce3805807dcf5299f43a7961caa864ace7b911715.php(280): Twig\Template->display(Array)\n#4 \/vendor\/twig\/twig\/src\/Template.php(394): TwigTemplate_48555e24c74f40810f5eeb59627fca3b4fb07d0f1207a4357d503e89e171bc34->doDisplay(Array, Array)\n#5 \/vendor\/twig\/twig\/src\/Template.php(367): Twig\Template->displayWithErrorHandling(Array, Array)\n#6 \/tmp\/templates_c\/b3\/b3776cd584957b0bf47259e998e5d5d15211875030884867096ed2935e5b26e8.php(258): Twig\Template->display(Array)\n#7 \/vendor\/twig\/twig\/src\/Template.php(394): __TwigTemplate_1705173160822dd32a5614400e4882f3653de9cb3154b7fdec96cad6e660b6ec->doDisplay(Array, Array)\n#8 \/vendor\/twig\/twig\/src\/Template.php(367): Twig\Template->displayWithErrorHandling(Array, Array)\n#9 \/vendor\/twig\/twig\/src\/Template.php(379): Twig\Template->display(Array)\n#10 \/vendor\/twig\/twig\/src\/TemplateWrapper.php(40): Twig\Template->render(Array, Array)\n#11 \/vendor\/twig\/twig\/src\/Environment.php(277): Twig\TemplateWrapper->render(Array)\n#12 \/core\/View.php(333): Twig\Environment->render('@CoreHome\/_data...', Array)\n#13 \/core\/View.php(318): Piwik\View->renderTwigTemplate()\n#14 \/core\/Plugin\/Visualization.php(271): Piwik\View->render()\n#15 \/core\/Plugin\/Report.php(320): Piwik\Plugin\Visualization->render()\n#16 \/plugins\/CoreHome\/Controller.php(60): Piwik\Plugin\Report->render()\n#17 [internal function]: Piwik\Plugins\CoreHome\Controller->renderReportWidget(Object(Piwik\Plugins\Actions\Reports\GetDownloads))\n#18 \/core\/FrontController.php(631): call_user_func_array(Array, Array)\n#19 \/core\/FrontController.php(169): Piwik\FrontController->doDispatch('Actions', 'getDownloads', Array)\n#20 \/core\/dispatch.php(32)
User login: christoph

URL: /index.php?date=2022-12-13&viewDataTable=table&module=Actions&format=html&action=getDownloads&idSite=2&period=day&random=6594&search_recursive=1&keep_totals_row=0&filter_sort_column=nb_visits&filter_sort_order=desc&filter_column_recursive=label&filter_pattern_recursive=file&filter_offset=0&filter_limit=-1&flat=0&totals=1

Referrer: /index.php?module=CoreHome&action=index&idSite=2&period=day&date=2022-12-13&updated=1

@bx80 commented on January 8th 2023 Contributor

Hi @tsteur, thanks for the back trace.

Using the provided URL on a local instance this works for me without error, both with and without data present.

From the code it looks like the datatable might be passing the 'hasAnyData()` check but doesn't actually have any returnable rows. Might be something specific to the data.

Can the issue be recreated consistently or with any other dataset?

@tsteur commented on January 9th 2023 Member

I can definitely reproduce it in that specific account. Viewing the report via the UI works. Exporting as XML and HTML too. After digging deeper seeing this might be actually caused by a special plugin of ours where it fetches data from the demo site. I'll close this one and will create an internal Jira issue.

Thanks for that 💯

This Issue was closed on January 9th 2023
Powered by GitHub Issue Mirror