Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#1526 closed Bug (fixed)

Undefined variable: sites error

Reported by: ts77 Owned by:
Priority: major Milestone:
Component: Core Keywords:
Cc: Sensitive: no

Description

(I'm having around 6k sites and from looking at the error message it seems to be related to the new site selector).

On upgrade (to 0.7) and now dashboard access I'm getting error messages (or better warnings) like the following. It makes the dashboard kind of unusable.

Errors:
Notice: Undefined variable: sites in /home/username/tracking-host/www/core/View.php on line 134

Backtrace -->
#0 Piwik_ErrorHandler(8, Undefined variable: sites, /home/username/tracking-host/www/core/View.php, 134, Array ([showWebsiteSelectorInUserInterface] => 0)) called at home/username/tracking-host/www/core/View.php:134
#1 Piwik_View->render() called at home/username/tracking-host/www/plugins/LanguagesManager/LanguagesManager.php:59
#2 Piwik_LanguagesManager->showLanguagesSelector(Piwik_Event_Notification Object ([_notificationName] => TopMenu.add,[_notificationObject] => ,[_notificationInfo] => Array (),[_notificationState] => 0,[_notificationCount] => 2))
#3 call_user_func_array(Array ([0] => Piwik_LanguagesManager Object (),[1] => showLanguagesSelector), Array ([0] => Piwik_Event_Notification Object ([_notificationName] => TopMenu.add,[_notificationObject] => ,[_notificationInfo] => Array (),[_notificationState] => 0,[_notificationCount] => 2))) called at home/username/tracking-host/www/libs/Event/Dispatcher.php:284
#4 Event_Dispatcher->postNotification(Piwik_Event_Notification Object ([_notificationName] => TopMenu.add,[_notificationObject] => ,[_notificationInfo] => Array (),[_notificationState] => 0,[_notificationCount] => 2), 1, ) called at home/username/tracking-host/www/core/PluginsManager.php:532
#5 Piwik_PostEvent(TopMenu.add) called at home/username/tracking-host/www/core/Menu/Top.php:58
#6 Piwik_Menu_Top->get() called at home/username/tracking-host/www/core/Menu/Top.php:71
#7 Piwik_GetTopMenu() called at home/username/tracking-host/www/core/Controller.php:335
#8 Piwik_Controller->setBasicVariablesView(Piwik_View Object ([] => /home/username/tracking-host/www/plugins/CoreHome/templates/index.tpl,[] => Piwik_Smarty Object ([template_dir] => Array ([0] => /home/username/tracking-host/www/plugins,[1] => /home/username/tracking-host/www/themes/default,[2] => /home/username/tracking-host/www/themes),[compile_dir] => /home/username/tracking-host/www/tmp/templates_c,[config_dir] => configs,[plugins_dir] => Array ([0] => /home/username/tracking-host/www/core/SmartyPlugins,[1] => /home/username/tracking-host/www/libs/Smarty/plugins),[debugging] => ,[error_reporting] => 6143,[debug_tpl] => ,[debugging_ctrl] => NONE,[compile_check] => 1,[force_compile] => ,[caching] => 0,[cache_dir] => /home/username/tracking-host/www/tmp/cache,[cache_lifetime] => 3600,[cache_modified_check] => ,[php_handling] => 0,[security] => ,[secure_dir] => Array (),[security_settings] => Array ([PHP_HANDLING] => ,[IF_FUNCS] => Array ([0] => array,[1] => list,[2] => isset,[3] => ...
#9 Piwik_Controller->setGeneralVariablesView(Piwik_View Object ([] => /home/username/tracking-host/www/plugins/CoreHome/templates/index.tpl,[] => Piwik_Smarty Object ([template_dir] => Array ([0] => /home/username/tracking-host/www/plugins,[1] => /home/username/tracking-host/www/themes/default,[2] => /home/username/tracking-host/www/themes),[compile_dir] => /home/username/tracking-host/www/tmp/templates_c,[config_dir] => configs,[plugins_dir] => Array ([0] => /home/username/tracking-host/www/core/SmartyPlugins,[1] => /home/username/tracking-host/www/libs/Smarty/plugins),[debugging] => ,[error_reporting] => 6143,[debug_tpl] => ,[debugging_ctrl] => NONE,[compile_check] => 1,[force_compile] => ,[caching] => 0,[cache_dir] => /home/username/tracking-host/www/tmp/cache,[cache_lifetime] => 3600,[cache_modified_check] => ,[php_handling] => 0,[security] => ,[secure_dir] => Array (),[security_settings] => Array ([PHP_HANDLING] => ,[IF_FUNCS] => Array ([0] => array,[1] => list,[2] => isset,[3] =...
#10 Piwik_CoreHome_Controller->getDefaultIndexView() called at home/username/tracking-host/www/plugins/CoreHome/Controller.php:89
#11 Piwik_CoreHome_Controller->index()
#12 call_user_func_array(Array ([0] => Piwik_CoreHome_Controller Object ([] => CoreHome,[] => 2010-07-28,[] => Piwik_Date Object ([] => 1280322534,[] => UTC),[] => 1,[] => Piwik_Site Object ([] => 1)),[1] => index), Array ()) called at home/username/tracking-host/www/core/FrontController.php:126
#13 Piwik_FrontController->dispatch() called at home/username/tracking-host/www/index.php:60

Notice: Undefined variable: sites in /home/username/tracking-host/www/core/View.php on line 134

Backtrace -->
#0 Piwik_ErrorHandler(8, Undefined variable: sites, /home/username/tracking-host/www/core/View.php, 134, Array ([showWebsiteSelectorInUserInterface] => 0)) called at home/username/tracking-host/www/core/View.php:134
#1 Piwik_View->render() called at home/username/tracking-host/www/plugins/CoreHome/Controller.php:90
#2 Piwik_CoreHome_Controller->index()
#3 call_user_func_array(Array ([0] => Piwik_CoreHome_Controller Object ([] => CoreHome,[] => 2010-07-28,[] => Piwik_Date Object ([] => 1280322534,[] => UTC),[] => 1,[] => Piwik_Site Object ([] => 1)),[1] => index), Array ()) called at home/username/tracking-host/www/core/FrontController.php:126
#4 Piwik_FrontController->dispatch() called at home/username/tracking-host/www/index.php:60

Change History (2)

comment:1 Changed 4 years ago by matt (mattab)

  • Resolution set to fixed
  • Status changed from new to closed

(In [2786]) Fixes #1526
removing feature to disable website selector, as website selector now works in all cases

comment:2 Changed 4 years ago by ts77

Thanks, that worked!

Note: See TracTickets for help on using tickets.