? ?
avatar alikon
alikon
21 Nov 2020

Steps to reproduce the issue

use php 8
go to Admin->Control Panel

Expected result

no warning

Actual result

[21-Nov-2020 08:46:20 UTC] PHP Warning:  FOFModelBehavior::onBeforeBuildQuery(): Argument #1 ($model) must be passed by reference, value given in /shared/httpd/joomla3/joomla-cms-staging/libraries/fof/utils/observable/event.php on line 63
[21-Nov-2020 08:46:20 UTC] PHP Stack trace:
[21-Nov-2020 08:46:20 UTC] PHP   1. {main}() /shared/httpd/joomla3/joomla-cms-staging/administrator/index.php:0
[21-Nov-2020 08:46:20 UTC] PHP   2. Joomla\CMS\Application\AdministratorApplication->execute() /shared/httpd/joomla3/joomla-cms-staging/administrator/index.php:51
[21-Nov-2020 08:46:20 UTC] PHP   3. Joomla\CMS\Application\AdministratorApplication->doExecute() /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Application/CMSApplication.php:196
[21-Nov-2020 08:46:20 UTC] PHP   4. Joomla\CMS\Application\AdministratorApplication->dispatch($component = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Application/AdministratorApplication.php:159
[21-Nov-2020 08:46:20 UTC] PHP   5. Joomla\CMS\Component\ComponentHelper::renderComponent($option = 'com_cpanel', $params = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Application/AdministratorApplication.php:101
[21-Nov-2020 08:46:20 UTC] PHP   6. Joomla\CMS\Component\ComponentHelper::executeComponent($path = '/shared/httpd/joomla3/joomla-cms-staging/administrator/components/com_cpanel/cpanel.php') /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Component/ComponentHelper.php:377
[21-Nov-2020 08:46:20 UTC] PHP   7. require_once() /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Component/ComponentHelper.php:402
[21-Nov-2020 08:46:20 UTC] PHP   8. CpanelController->execute($task = NULL) /shared/httpd/joomla3/joomla-cms-staging/administrator/components/com_cpanel/cpanel.php:15
[21-Nov-2020 08:46:20 UTC] PHP   9. CpanelController->display($cachable = *uninitialized*, $urlparams = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/libraries/src/MVC/Controller/BaseController.php:710
[21-Nov-2020 08:46:20 UTC] PHP  10. CpanelViewCpanel->display($tpl = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/libraries/src/MVC/Controller/BaseController.php:672
[21-Nov-2020 08:46:20 UTC] PHP  11. PostinstallModelMessages->getItemList($overrideLimits = *uninitialized*, $group = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/administrator/components/com_cpanel/views/cpanel/view.html.php:53
[21-Nov-2020 08:46:20 UTC] PHP  12. PostinstallModelMessages->buildQuery($overrideLimits = FALSE) /shared/httpd/joomla3/joomla-cms-staging/libraries/fof/model/model.php:1221
[21-Nov-2020 08:46:20 UTC] PHP  13. PostinstallModelMessages->buildQuery($overrideLimits = FALSE) /shared/httpd/joomla3/joomla-cms-staging/administrator/components/com_postinstall/models/messages.php:30
[21-Nov-2020 08:46:20 UTC] PHP  14. FOFModelDispatcherBehavior->trigger($event = 'onBeforeBuildQuery', $args = [0 => class PostinstallModelMessages { protected $__state_set = NULL; protected $_db = class FOFDatabaseDriverJoomla { ... }; protected $event_after_delete = 'onContentAfterDelete'; protected $event_after_save = 'onContentAfterSave'; protected $event_before_delete = 'onContentBeforeDelete'; protected $event_before_save = 'onContentBeforeSave'; protected $event_change_state = 'onContentChangeState'; protected $event_clean_cache = NULL; protected $id_list = NULL; protected $id = 0; protected $input = class FOFInput { ... }; protected $list = NULL; protected $name = 'messages'; protected $option = 'com_postinstall'; protected $otable = NULL; protected $pagination = NULL; protected $record = NULL; protected $state = class FOFUtilsObject { ... }; protected $table = 'message'; protected $total = NULL; protected $_savestate = FALSE; protected $_forms = [...]; protected $_formData = [...]; protected $configProvider = class FOFConfigProvider { ... }; protected $modelDispatcher = class FOFModelDispatcherBehavior { ... }; protected $default_behaviors = [...]; protected $_behaviorParams = [...]; protected $_errors = [...] }, 1 => class JDatabaseQueryPdomysql { protected $offset = NULL; protected $limit = NULL; protected $db = class JDatabaseDriverPdomysql { ... }; protected $sql = NULL; protected $type = ''; protected $element = NULL; protected $select = NULL; protected $delete = NULL; protected $update = NULL; protected $insert = NULL; protected $from = NULL; protected $join = NULL; protected $set = NULL; protected $where = NULL; protected $group = NULL; protected $having = NULL; protected $columns = NULL; protected $values = NULL; protected $order = NULL; protected $autoIncrementField = NULL; protected $call = NULL; protected $exec = NULL; protected $union = NULL; protected $unionAll = NULL; protected $selectRowNumber = NULL }]) /shared/httpd/joomla3/joomla-cms-staging/libraries/fof/model/model.php:2071
[21-Nov-2020 08:46:20 UTC] PHP  15. FOFModelBehaviorFilters->update($args = [0 => class PostinstallModelMessages { protected $__state_set = NULL; protected $_db = class FOFDatabaseDriverJoomla { ... }; protected $event_after_delete = 'onContentAfterDelete'; protected $event_after_save = 'onContentAfterSave'; protected $event_before_delete = 'onContentBeforeDelete'; protected $event_before_save = 'onContentBeforeSave'; protected $event_change_state = 'onContentChangeState'; protected $event_clean_cache = NULL; protected $id_list = NULL; protected $id = 0; protected $input = class FOFInput { ... }; protected $list = NULL; protected $name = 'messages'; protected $option = 'com_postinstall'; protected $otable = NULL; protected $pagination = NULL; protected $record = NULL; protected $state = class FOFUtilsObject { ... }; protected $table = 'message'; protected $total = NULL; protected $_savestate = FALSE; protected $_forms = [...]; protected $_formData = [...]; protected $configProvider = class FOFConfigProvider { ... }; protected $modelDispatcher = class FOFModelDispatcherBehavior { ... }; protected $default_behaviors = [...]; protected $_behaviorParams = [...]; protected $_errors = [...] }, 1 => class JDatabaseQueryPdomysql { protected $offset = NULL; protected $limit = NULL; protected $db = class JDatabaseDriverPdomysql { ... }; protected $sql = NULL; protected $type = ''; protected $element = NULL; protected $select = NULL; protected $delete = NULL; protected $update = NULL; protected $insert = NULL; protected $from = NULL; protected $join = NULL; protected $set = NULL; protected $where = NULL; protected $group = NULL; protected $having = NULL; protected $columns = NULL; protected $values = NULL; protected $order = NULL; protected $autoIncrementField = NULL; protected $call = NULL; protected $exec = NULL; protected $union = NULL; protected $unionAll = NULL; protected $selectRowNumber = NULL }]) /shared/httpd/joomla3/joomla-cms-staging/libraries/fof/utils/observable/dispatcher.php:146
[21-Nov-2020 08:46:20 UTC] PHP Warning:  FOFModelBehaviorFilters::onAfterBuildQuery(): Argument #1 ($model) must be passed by reference, value given in /shared/httpd/joomla3/joomla-cms-staging/libraries/fof/utils/observable/event.php on line 63
[21-Nov-2020 08:46:20 UTC] PHP Stack trace:
[21-Nov-2020 08:46:20 UTC] PHP   1. {main}() /shared/httpd/joomla3/joomla-cms-staging/administrator/index.php:0
[21-Nov-2020 08:46:20 UTC] PHP   2. Joomla\CMS\Application\AdministratorApplication->execute() /shared/httpd/joomla3/joomla-cms-staging/administrator/index.php:51
[21-Nov-2020 08:46:20 UTC] PHP   3. Joomla\CMS\Application\AdministratorApplication->doExecute() /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Application/CMSApplication.php:196
[21-Nov-2020 08:46:20 UTC] PHP   4. Joomla\CMS\Application\AdministratorApplication->dispatch($component = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Application/AdministratorApplication.php:159
[21-Nov-2020 08:46:20 UTC] PHP   5. Joomla\CMS\Component\ComponentHelper::renderComponent($option = 'com_cpanel', $params = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Application/AdministratorApplication.php:101
[21-Nov-2020 08:46:20 UTC] PHP   6. Joomla\CMS\Component\ComponentHelper::executeComponent($path = '/shared/httpd/joomla3/joomla-cms-staging/administrator/components/com_cpanel/cpanel.php') /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Component/ComponentHelper.php:377
[21-Nov-2020 08:46:20 UTC] PHP   7. require_once() /shared/httpd/joomla3/joomla-cms-staging/libraries/src/Component/ComponentHelper.php:402
[21-Nov-2020 08:46:20 UTC] PHP   8. CpanelController->execute($task = NULL) /shared/httpd/joomla3/joomla-cms-staging/administrator/components/com_cpanel/cpanel.php:15
[21-Nov-2020 08:46:20 UTC] PHP   9. CpanelController->display($cachable = *uninitialized*, $urlparams = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/libraries/src/MVC/Controller/BaseController.php:710
[21-Nov-2020 08:46:20 UTC] PHP  10. CpanelViewCpanel->display($tpl = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/libraries/src/MVC/Controller/BaseController.php:672
[21-Nov-2020 08:46:20 UTC] PHP  11. PostinstallModelMessages->getItemList($overrideLimits = *uninitialized*, $group = *uninitialized*) /shared/httpd/joomla3/joomla-cms-staging/administrator/components/com_cpanel/views/cpanel/view.html.php:53
[21-Nov-2020 08:46:20 UTC] PHP  12. PostinstallModelMessages->buildQuery($overrideLimits = FALSE) /shared/httpd/joomla3/joomla-cms-staging/libraries/fof/model/model.php:1221
[21-Nov-2020 08:46:20 UTC] PHP  13. PostinstallModelMessages->buildQuery($overrideLimits = FALSE) /shared/httpd/joomla3/joomla-cms-staging/administrator/components/com_postinstall/models/messages.php:30
[21-Nov-2020 08:46:20 UTC] PHP  14. FOFModelDispatcherBehavior->trigger($event = 'onAfterBuildQuery', $args = [0 => class PostinstallModelMessages { protected $__state_set = TRUE; protected $_db = class FOFDatabaseDriverJoomla { ... }; protected $event_after_delete = 'onContentAfterDelete'; protected $event_after_save = 'onContentAfterSave'; protected $event_before_delete = 'onContentBeforeDelete'; protected $event_before_save = 'onContentBeforeSave'; protected $event_change_state = 'onContentChangeState'; protected $event_clean_cache = NULL; protected $id_list = NULL; protected $id = 0; protected $input = class FOFInput { ... }; protected $list = NULL; protected $name = 'messages'; protected $option = 'com_postinstall'; protected $otable = NULL; protected $pagination = NULL; protected $record = NULL; protected $state = class FOFUtilsObject { ... }; protected $table = 'message'; protected $total = NULL; protected $_savestate = FALSE; protected $_forms = [...]; protected $_formData = [...]; protected $configProvider = class FOFConfigProvider { ... }; protected $modelDispatcher = class FOFModelDispatcherBehavior { ... }; protected $default_behaviors = [...]; protected $_behaviorParams = [...]; protected $_errors = [...] }, 1 => class JDatabaseQueryPdomysql { protected $offset = NULL; protected $limit = NULL; protected $db = class JDatabaseDriverPdomysql { ... }; protected $sql = NULL; protected $type = 'select'; protected $element = NULL; protected $select = class JDatabaseQueryElement { ... }; protected $delete = NULL; protected $update = NULL; protected $insert = NULL; protected $from = class JDatabaseQueryElement { ... }; protected $join = NULL; protected $set = NULL; protected $where = NULL; protected $group = NULL; protected $having = NULL; protected $columns = NULL; protected $values = NULL; protected $order = class JDatabaseQueryElement { ... }; protected $autoIncrementField = NULL; protected $call = NULL; protected $exec = NULL; protected $union = NULL; protected $unionAll = NULL; protected $selectRowNumber = NULL }]) /shared/httpd/joomla3/joomla-cms-staging/libraries/fof/model/model.php:2115
[21-Nov-2020 08:46:20 UTC] PHP  15. FOFModelBehaviorFilters->update($args = [0 => class PostinstallModelMessages { protected $__state_set = TRUE; protected $_db = class FOFDatabaseDriverJoomla { ... }; protected $event_after_delete = 'onContentAfterDelete'; protected $event_after_save = 'onContentAfterSave'; protected $event_before_delete = 'onContentBeforeDelete'; protected $event_before_save = 'onContentBeforeSave'; protected $event_change_state = 'onContentChangeState'; protected $event_clean_cache = NULL; protected $id_list = NULL; protected $id = 0; protected $input = class FOFInput { ... }; protected $list = NULL; protected $name = 'messages'; protected $option = 'com_postinstall'; protected $otable = NULL; protected $pagination = NULL; protected $record = NULL; protected $state = class FOFUtilsObject { ... }; protected $table = 'message'; protected $total = NULL; protected $_savestate = FALSE; protected $_forms = [...]; protected $_formData = [...]; protected $configProvider = class FOFConfigProvider { ... }; protected $modelDispatcher = class FOFModelDispatcherBehavior { ... }; protected $default_behaviors = [...]; protected $_behaviorParams = [...]; protected $_errors = [...] }, 1 => class JDatabaseQueryPdomysql { protected $offset = NULL; protected $limit = NULL; protected $db = class JDatabaseDriverPdomysql { ... }; protected $sql = NULL; protected $type = 'select'; protected $element = NULL; protected $select = class JDatabaseQueryElement { ... }; protected $delete = NULL; protected $update = NULL; protected $insert = NULL; protected $from = class JDatabaseQueryElement { ... }; protected $join = NULL; protected $set = NULL; protected $where = NULL; protected $group = NULL; protected $having = NULL; protected $columns = NULL; protected $values = NULL; protected $order = class JDatabaseQueryElement { ... }; protected $autoIncrementField = NULL; protected $call = NULL; protected $exec = NULL; protected $union = NULL; protected $unionAll = NULL; protected $selectRowNumber = NULL }]) /shared/httpd/joomla3/joomla-cms-staging/libraries/fof/utils/observable/dispatcher.php:146

System information (as much as possible)

php 8
jooomla 3 staging/rc

avatar alikon alikon - open - 21 Nov 2020
avatar joomla-cms-bot joomla-cms-bot - change - 21 Nov 2020
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 21 Nov 2020
avatar alikon alikon - change - 21 Nov 2020
Labels Added: ?
avatar alikon alikon - labeled - 21 Nov 2020
avatar HLeithner
HLeithner - comment - 21 Nov 2020

I can't reproduce this, do you have any 3rd party extensions installed?

avatar alikon
alikon - comment - 21 Nov 2020

No, clean staging branch with php8 rc4
Screenshot from 2020-11-21 10-12-27

avatar HLeithner
HLeithner - comment - 21 Nov 2020

can you try to apply a similar patch like #30608 to libraries/fof/utils/observable/event.php line 63?

avatar alikon
alikon - comment - 21 Nov 2020

i've already done that....with no luck
i'm currently unable to go deep cause still figthing with my setup docker/php8/Xdebug v3.0.0RC2-dev

avatar HLeithner
HLeithner - comment - 21 Nov 2020

Compiling php8-rc5 now (missed it till now)

avatar HLeithner
HLeithner - comment - 21 Nov 2020

@alikon do you get the error also without xdebug?

avatar alikon
alikon - comment - 21 Nov 2020

yes
Screenshot from 2020-11-21 13-03-59

avatar HLeithner
HLeithner - comment - 21 Nov 2020

I think you have to fix it I can't reproduce it and no one else who tested php 8.0 (since it's the first admin page ;-)

avatar alikon alikon - change - 22 Nov 2020
Status New Closed
Closed_Date 0000-00-00 00:00:00 2020-11-22 07:48:36
Closed_By alikon
avatar alikon
alikon - comment - 22 Nov 2020

ok let's close it

avatar alikon alikon - close - 22 Nov 2020
avatar HLeithner
HLeithner - comment - 22 Nov 2020

So you don't try to find the problem and provide a pr?

avatar alikon
alikon - comment - 22 Nov 2020

i'll wait for the stable version of both php8 and xdebug3....maybe i've made some mistake on my local settings to run on -dev environment

avatar Cecile-GH
Cecile-GH - comment - 24 Nov 2020

Hello, I got two similar warning messages when upgrading from php7.2.10 to php7.3.24. However, they disappear when I deactivate the php_xdebug extension. This bug seems to be Akeeba related. Can anyone tell me how to fix it?

Messages (localhost > Joomla! 3.9.22 > Control Panel) :

Warning: Parameter 1 to FOFModelBehavior::onBeforeBuildQuery() expected to be a reference, value given in C:\wamp64\www\export\libraries\fof\utils\observable\event.php on line 63

Warning: Parameter 1 to FOFModelBehaviorFilters::onAfterBuildQuery() expected to be a reference, value given in C:\wamp64\www\export\libraries\fof\utils\observable\event.php on line 63


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/31446.
avatar HLeithner
HLeithner - comment - 24 Nov 2020

No it's not akkeba it's only FOF which is an old version bundled with joomla.

avatar Cecile-GH
Cecile-GH - comment - 25 Nov 2020

@HLeithner
Thank you.
"only FOF":
Does it mean that there is actually no problem — that I will not get stuck when working on my local host?
If so, how can I have the warnings removed without deactivating the php_xdebug extension?


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/31446.

avatar HLeithner
HLeithner - comment - 25 Nov 2020

actually I can't replicate the issues, it would be awesome if someone who can reproduce the problem find and solve it.

avatar Cecile-GH
Cecile-GH - comment - 30 Nov 2020

@HLeithner
Thanks. I'll wait and see.

avatar alikon
alikon - comment - 30 Nov 2020

please test #31537

avatar Cecile-GH
Cecile-GH - comment - 19 Apr 2021

Thank you. FYI, problem solved with latest Joomla updates.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/31446.

Add a Comment

Login with GitHub to post a comment