@anonymous-piwik-user opened this issue on July 6th 2011

See reportings in http://forum.piwik.org/read.php?2,78979

Goals plugin on dashbaord Fatal error: Class 'Piwik_DataTable_Filter_AddColumnsProcessedMetrics' not found in /home/piwik/public_html/core/DataTable/Filter/AddColumnsProcessedMetricsGoal.php on line 18

The class 'Piwik_DataTable_Filter_AddColumnsProcessedMetrics' that 'Piwik_DataTable_Filter_AddColumnsProcessedMetricsGoal' is trying to extend doesnt appear to be loaded.

By adding class 'Piwik_DataTable_Filter_AddColumnsProcessedMetrics' to '/core/DataTable/Filter/AddColumnsProcessedMetricsGoal.php' allows the class 'Piwik_DataTable_Filter_AddColumnsProcessedMetricsGoal' to extend and then the Goals plugin works.

Adding the following code before trying to extend the class fixes the issue as a temporary solution:

if (!class_exists('Piwik_DataTable_Filter_AddColumnsProcessedMetrics', false)) { include(PIWIK_INCLUDE_PATH .'/core/DataTable/Filter/AddColumnsProcessedMetrics.php'); }

Patch attached

I think some sort of check for dependent classes should be introduced and should fail during automated tests.

PHP 5.3 Keywords: class extends epic fail

@anonymous-piwik-user commented on July 6th 2011
@anonymous-piwik-user commented on July 6th 2011

This is in version 1.5.1 of Piwik (updated 3 days ago)

This issue was closed on July 7th 2011
Powered by GitHub Issue Mirror