Bug #80897
closedCLI typo3/sysext/core/bin/typo3 throws PHP Warning
100%
Description
With preset "debug" activated in Install-Tool,
calling the cli typo3/sysext/core/bin/typo3 throws:
Uncaught TYPO3 Exception #1476107295: PHP Warning: Invalid argument supplied for foreach() in /var/www/vendor/typo3/cms/typo3/sysext/core/Classes/Utility/RootlineUtility.php line 287
thrown in file /var/www/vendor/typo3/cms/typo3/sysext/core/Classes/Error/ErrorHandler.php
in line 112
Updated by Benni Mack almost 7 years ago
- Status changed from New to Needs Feedback
Do you provide any arguments / specific command in the Command Line?
Updated by R3 H6 almost 7 years ago
After some while I realized, it has nothing to do with the debug settings.
The error occurs on an TYPO3 installation with a custom extension which has some symfony based commands.
If I deinstall and install the extension again, the error disappears for a while, but comes back after a while.
So I guess it something related to caching.
In the configure method only setDescription, addArgument and addOption are used, not object initialization or so.
Issue can be closed, if nobody experience same problem with custom commands...
Updated by Riccardo De Contardi almost 7 years ago
- Status changed from Needs Feedback to Closed
Thank you for your feedback; I'll close this issue for now. If someone experiences the same issue and wants to add more detail , then please reopen the issue (or contact me and I will do :) )
Updated by ondro no-lastname-given almost 7 years ago
R3 H6 wrote:
With preset "debug" activated in Install-Tool,
calling the cli typo3/sysext/core/bin/typo3 throws:Uncaught TYPO3 Exception #1476107295: PHP Warning: Invalid argument supplied for foreach() in /var/www/vendor/typo3/cms/typo3/sysext/core/Classes/Utility/RootlineUtility.php line 287
thrown in file /var/www/vendor/typo3/cms/typo3/sysext/core/Classes/Error/ErrorHandler.php
in line 112
Can confirm, same behaviour for typo3 v8.7.1
When I set debug = false, console works with no problems
Setting back debug to true console works until I clear caches
Updated by Thomas Maroschik almost 7 years ago
- Status changed from Closed to Needs Feedback
Ok, here's how to reproduce the issue in 8.7.1:
- Clear cache via install tool
- One shouldn't be logged in in the BE, because background AJAX requests populate TCA cache
- Call on the commandline
vendor/bin/typo3 help
- See the warning the issue author already described
The change https://review.typo3.org/#/c/52753/ fixes that problem. But it isn't solved in 8.7.
I would suggest to backport the behavior from master, or move TCA loading from the handleRequest
method in the \TYPO3\CMS\Core\Console\CommandRequestHandler
to it's __construct
method. This way CLI works under every condition and eID is left untouched.
Updated by Gerrit Code Review almost 7 years ago
- Status changed from Needs Feedback to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/53270
Updated by Gerrit Code Review almost 7 years ago
Patch set 1 for branch TYPO3_8-7 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/53279
Updated by Gerrit Code Review almost 7 years ago
Patch set 2 for branch TYPO3_8-7 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/53279
Updated by Benni Mack almost 7 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 7d469851d00f8687b51708182ad87627f15250c1.
Updated by Christian Kuhn almost 7 years ago
- Related to Bug #81795: New CLI API is broken with empty cache added