Closed
Description
Symfony version(s) affected
4.4.33
Description
install new symfony:
symfony new --version=4.4 .
composer require 'nucleos/user-admin-bundle'
composer require 'sonata-project/doctrine-orm-admin-bundle'
tell nucleos to use orm:
nucleos_user:
firewall_name: main
db_driver: orm
try to clear the cache:
php bin/console cache:clear -vvvv
How to reproduce
The Crash happen when calling any console command: php bin/console cache:clear -vvvv
Possible Solution
No response
Additional Context
The Exception:
In ContainerBuilder.php line 1030:
[Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException]
You have requested a non-existent service ".service_locator.I3K77mT".
Exception trace:
at /opt/project/vendor/symfony/dependency-injection/ContainerBuilder.php:1030
Symfony\Component\DependencyInjection\ContainerBuilder->getDefinition() at /opt/project/vendor/symfony/translation/DependencyInjection/TranslatorPathsPass.php:126
Symfony\Component\Translation\DependencyInjection\TranslatorPathsPass->findControllerArguments() at /opt/project/vendor/symfony/translation/DependencyInjection/TranslatorPathsPass.php:48
Symfony\Component\Translation\DependencyInjection\TranslatorPathsPass->process() at /opt/project/vendor/symfony/dependency-injection/Compiler/Compiler.php:94
Symfony\Component\DependencyInjection\Compiler\Compiler->compile() at /opt/project/vendor/symfony/dependency-injection/ContainerBuilder.php:762
Symfony\Component\DependencyInjection\ContainerBuilder->compile() at /opt/project/vendor/symfony/http-kernel/Kernel.php:596
Symfony\Component\HttpKernel\Kernel->initializeContainer() at /opt/project/vendor/symfony/http-kernel/Kernel.php:136
Symfony\Component\HttpKernel\Kernel->boot() at /opt/project/vendor/symfony/framework-bundle/Console/Application.php:169
Symfony\Bundle\FrameworkBundle\Console\Application->registerCommands() at /opt/project/vendor/symfony/framework-bundle/Console/Application.php:75
Symfony\Bundle\FrameworkBundle\Console\Application->doRun() at /opt/project/vendor/symfony/console/Application.php:149
Symfony\Component\Console\Application->run() at /opt/project/bin/console:42
for some reason the service got inlined to Twig, and it isn't the only one.
var/cache/dev/srcApp_KernelDevDebugContainerCompiler.log:
Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass: Inlined service ".service_locator.I3K77mT" to "twig".
Some Debug told me that the Service Locator with this specific name was created at RegisterControllerArgumentLocatorsPass. The List of $controllers
there is empty for some reason.
if db_driver isn't defined it somehow is not a problem?