Bug #27836
closedFatal error on installing an extension with dependencies
100%
Description
I tried to install the aloha editor for BE demo by Kay. It worked fine with the old em.
Fatal error: Call to a member function section() on a non-object in /home/phil/t3-playground/t3-git/typo3/sysext/em/classes/install/class.tx_em_install.php on line 582 Call Stack # Time Memory Function Location 1 0.0003 652120 {main}( ) ../ajax.php:0 2 0.0957 15486328 t3lib_div::callUserFunction( ) ../ajax.php:73 3 0.0961 15536944 call_user_func_array ( ) ../class.t3lib_div.php:4900 4 0.0961 15537024 t3lib_extjs_ExtDirectRouter->route( ) ../class.t3lib_div.php:4900 5 0.0972 15668472 t3lib_extjs_ExtDirectRouter->processRpc( ) ../class.t3lib_extjs_extdirectrouter.php:106 6 0.1115 17976048 call_user_func_array ( ) ../class.t3lib_extjs_extdirectrouter.php:161 7 0.1115 17976080 tx_em_Connection_ExtDirectServer->uploadExtension( ) ../class.t3lib_extjs_extdirectrouter.php:161 8 0.3482 40406728 tx_em_Install->installExtension( ) ../class.tx_em_connection_extdirectserver.php:1372 9 0.3947 41676872 tx_em_Install->checkDependencies( ) ../class.tx_em_install.php:165
Updated by Xavier Perseguers over 13 years ago
- Target version changed from 1281 to 4.6.0-beta1
Updated by Steffen Kamper over 13 years ago
I tried to reproduce, but didn't had any error with uploading t3x
Please provide more information on how tor reproduce.
Updated by Philipp Gampe over 13 years ago
It worked this morning, except that the install bar did not disappear.
The extension was unpacked on the server. I do not recall whether it was installed or not, but I think it was not.
I will test again this evening and see, if I get any Javascript errors.
Updated by Xavier Perseguers over 13 years ago
- Target version changed from 4.6.0-beta1 to 4.6.0-beta2
Updated by Jigal van Hemert over 13 years ago
I got a similar error:
Call to a member function section() on a non-object in /var/www/vhosts/<domain>/httpdocs/typo3_src-4.5.4/typo3/sysext/em/classes/install/class.tx_em_install.php on line 633
while uploading a t3x file.
At that location the EM tries to check suggested dependencies. The t3x was of the solr EAP extension and I know it suggests devlog and requires pagebrowse.
I suspect that the problem occurs while uploading a t3x and the EM wants to display the dialogue about installing suggestions.
Updated by Jigal van Hemert over 13 years ago
After installing the suggested extension first, the upload worked flawlessly.
Updated by Philipp Gampe over 13 years ago
Thanks for looking into it Jigal,
now I also remember that the mentioned extension from Kay listed a conflict with RTE.
I do not think it had a (positiv) dependency, but I guess the conflict is not handled very diffently.
Updated by Xavier Perseguers about 13 years ago
- Target version changed from 4.6.0-beta2 to 4.6.0-beta3
Updated by Oliver Hader about 13 years ago
- Target version changed from 4.6.0-beta3 to 4.6.0-RC1
Updated by Xavier Perseguers about 13 years ago
- Status changed from New to Accepted
- Assignee deleted (
Steffen Kamper)
I can reproduce it when I upload an extension having a suggested dependency that is not yet loaded (= activated).
Updated by Oliver Hader about 13 years ago
- Subject changed from EM: fatal error while uploading a t3x to Fatal error on installing an extension with dependencies
Updated by Xavier Perseguers about 13 years ago
- Target version changed from 4.6.0-RC1 to 4.6.0
Updated by Steffen Gebert about 13 years ago
... and I got
Warning: Invalid argument supplied for foreach() in typo3/sysext/em/classes/install/class.tx_em_install.php on line 644 Call Stack # Time Memory Function Location 1 0.0001 648448 {main}( ) ../ajax.php:0 2 0.1500 5294840 t3lib_div::callUserFunction( ) ../ajax.php:73 3 0.1503 5299168 call_user_func_array ( ) ../class.t3lib_div.php:4677 4 0.1503 5299248 t3lib_extjs_ExtDirectRouter->route( ) ../class.t3lib_div.php:4677 5 0.1509 5329480 t3lib_extjs_ExtDirectRouter->processRpc( ) ../class.t3lib_extjs_extdirectrouter.php:106 6 0.1702 5972536 call_user_func_array ( ) ../class.t3lib_extjs_extdirectrouter.php:183 7 0.1703 5972568 tx_em_Connection_ExtDirectServer->uploadExtension( ) ../class.t3lib_extjs_extdirectrouter.php:183 8 0.3655 8928080 tx_em_Install->installExtension( ) ../class.tx_em_connection_extdirectserver.php:1421 9 0.4598 10888568 tx_em_Install->checkDependencies( ) ../class.tx_em_install.php:170
I still hope that it's only one bug to fix, not 20.. ;)
Updated by Steffen Gebert about 13 years ago
I guess we need a rewrite of the EM for a nice implementation..
This functional part is totally missing I would say. We're in a (kind of) AJAX context while sending the file and must ask for user input, whether to install the dependency. In contrast to importing an extension with dependencies from TER, which opens a new frame, uploading an extension file does not.
This is (I think) e.g. reflected with the check if ($this->parentObject instanceof SC_mod_tools_em_index)
in the middle of tx_em_install::checkDependencies()
.
I have only one solution for that: Uninstall the extension directly after upload (yes, there's some magic, which directly installs it) and let the EM show the extension list, which has the extension key as filter. Then the user can hit the Install button and we have to old-school HTML magic from back in 1998, which deals with the dependencies. Totally unAJAXy. To be honest, I think that's the exact way, how importing an extension from TER ends up. So maybe it isn't even that bad..
Updated by Mr. Hudson about 13 years ago
- Status changed from Accepted to Under Review
Patch set 1 of change I26e8f12df7df7be3c21a6e7735635e38df70e87b has been pushed to the review server.
It is available at http://review.typo3.org/6202
Updated by Steffen Gebert about 13 years ago
Only one review by testing is missing!
Updated by Steffen Gebert about 13 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 4b8ee263875c9c6286b2066d393f2821fc40301c.
Updated by Riccardo De Contardi about 7 years ago
- Status changed from Resolved to Closed