Bug #93569
closedconsole command 'extension:activate' throws error
100%
Description
Since #93442 (https://review.typo3.org/c/Packages/TYPO3.CMS/+/67648) the console command
bin/typo3 extension:activate xxxfails with the following error
Uncaught TYPO3 Exception Too few arguments to function TYPO3\CMS\Core\ExpressionLanguage\ProviderConfigurationLoader::__construct(), 0 passed in /some/path/typo3/sysext/core/Classes/Utility/GeneralUtility.php on line 3222 and exactly 2 expected thrown in file /some/path/typo3/sysext/core/Classes/ExpressionLanguage/ProviderConfigurationLoader.php in line 35
Tested with completely new TYPO3 instances (empty 'var/' directory and so on).
Updated by Ralf Zimmermann over 3 years ago
\TYPO3\CMS\Core\Console\CommandApplication->run tries to bootstrap a non-failsafe container https://github.com/TYPO3/TYPO3.CMS/blob/f22a127800fff528296dffa5ffbdd518d4811611/typo3/sysext/core/Classes/Console/CommandApplication.php#L103.
Before that there is only the failsafe container available.
"$this->application->find()" for the command "extension:activate" fires a DI chain (on the failsafe container) which, however, already needs an non-failsafe container (constructor DI for an extbase repo -> configuration manager -> TypoScript -> condition matcher -> expression language)
A shrinked trace:
Symfony\Component\Console\Application->find\\('extension:activate') Code
TYPO3\CMS\Core\Console\CommandRegistry->getInstance('TYPO3\\CMS\\Extensionmanager\\Command\ActivateExtensionCommand') Code
- $this->container->get('TYPO3\\CMS\\Extensionmanager\\Command\ActivateExtensionCommand') // $this->container === TYPO3\CMS\Core\DependencyInjection\FailsafeContainer
ActivateExtensionCommand->__construct->InstallUtility $installUtility Code
InstallUtility->injectListUtility(ListUtility $listUtility) Code
ListUtility->injectExtensionRepository(ExtensionRepository $extensionRepository) Code
ExtensionRepository->objectManager->get(QuerySettingsInterface::class) Code
TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings->initializeObject Code
- $configurationManager->isFeatureEnabled('ignoreAllEnableFieldsInBe') // $configurationManager === TYPO3\CMS\Extbase\Configuration\ConfigurationManager
ConfigurationManager->isFeatureEnabled Code
- $this->concreteConfigurationManager->getConfiguration($extensionName, $pluginName)
- $template->generateConfig() // $template == TYPO3\CMS\Core\TypoScript\TemplateService Code
$matchObj = GeneralUtility::makeInstance(ConditionMatcher::class) Code
$this->expressionLanguageResolver = GeneralUtility::makeInstance(\TYPO3\CMS\Core\ExpressionLanguage\Resolver::class, 'typoscript', $this->expressionLanguageResolverVariables) Code
GeneralUtility::makeInstance(\TYPO3\CMS\Core\ExpressionLanguage\ProviderConfigurationLoader::class) Code
GeneralUtility->makeInstance Code
- self::$container->has(\TYPO3\CMS\Core\ExpressionLanguage\ProviderConfigurationLoader) // self::$container === TYPO3\CMS\Core\DependencyInjection\FailsafeContainer
- self::$container->has(\TYPO3\CMS\Core\ExpressionLanguage\ProviderConfigurationLoader) === false
Updated by Christian Kuhn over 3 years ago
- Related to Task #93442: Inject PackageManager and cache into ExpressionLanguage/ProviderConfigurationLoader added
Updated by Gerrit Code Review over 3 years ago
- Status changed from New 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/c/Packages/TYPO3.CMS/+/68254
Updated by Gerrit Code Review over 3 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/68254
Updated by Gerrit Code Review over 3 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/68254
Updated by Gerrit Code Review over 3 years ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/68254
Updated by Benjamin Franzke over 3 years ago
- Related to Bug #86248: CLI upgrade wizards can not be invoked fully uncached added
Updated by Benjamin Franzke over 3 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 370de7f974d206003fe3e0e5934d2abb62f4806f.
Updated by Benjamin Franzke over 3 years ago
- Related to Bug #93721: Activating/Deactivating extensions through CLI results in a PHP error added