doctrine / DoctrineModule

Doctrine Module for Laminas
http://www.doctrine-project.org/projects/doctrine-module.html
MIT License
398 stars 269 forks source link

Invalid event subscriber "Closure" given, must be a service name, class name or an instance implementing Doctrine\Common\EventSubscriber #54

Closed ghost closed 12 years ago

ghost commented 12 years ago
File:

vendor\doctrine\doctrine-module\src\DoctrineModule\Service\EventManagerFactory.php:58

Message:

Invalid event subscriber "Closure" given, must be a service name, class name or an instance implementing Doctrine\Common\EventSubscriber

Stack trace:

#0 [internal function]: DoctrineModule\Service\EventManagerFactory->createService(Object(Zend\ServiceManager\ServiceManager), 'doctrine.eventm...', 'doctrine.eventm...')
#1 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(672): call_user_func(Array, Object(Zend\ServiceManager\ServiceManager), 'doctrine.eventm...', 'doctrine.eventm...')
#2 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(763): Zend\ServiceManager\ServiceManager->createServiceViaCallback(Array, 'doctrine.eventm...', 'doctrine.eventm...')
#3 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(438): Zend\ServiceManager\ServiceManager->createFromFactory('doctrine.eventm...', 'doctrine.eventm...')
#4 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(391): Zend\ServiceManager\ServiceManager->create(Array)
#5 vendor\doctrine\doctrine-module\src\DoctrineModule\Service\ConnectionFactory.php(57): Zend\ServiceManager\ServiceManager->get('doctrine.eventm...')
#6 [internal function]: DoctrineModule\Service\ConnectionFactory->createService(Object(Zend\ServiceManager\ServiceManager), 'doctrine.connec...', 'doctrine.connec...')
#7 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(672): call_user_func(Array, Object(Zend\ServiceManager\ServiceManager), 'doctrine.connec...', 'doctrine.connec...')
#8 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(763): Zend\ServiceManager\ServiceManager->createServiceViaCallback(Array, 'doctrine.connec...', 'doctrine.connec...')
#9 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(438): Zend\ServiceManager\ServiceManager->createFromFactory('doctrine.connec...', 'doctrine.connec...')
#10 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(391): Zend\ServiceManager\ServiceManager->create(Array)
#11 vendor\doctrine\doctrine-orm-module\src\DoctrineORMModule\Service\EntityManagerFactory.php(14): Zend\ServiceManager\ServiceManager->get('doctrine.connec...')
#12 [internal function]: DoctrineORMModule\Service\EntityManagerFactory->createService(Object(Zend\ServiceManager\ServiceManager), 'doctrine.entity...', 'zfcuser_doctrin...')
#13 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(672): call_user_func(Array, Object(Zend\ServiceManager\ServiceManager), 'doctrine.entity...', 'zfcuser_doctrin...')
#14 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(763): Zend\ServiceManager\ServiceManager->createServiceViaCallback(Array, 'doctrine.entity...', 'zfcuser_doctrin...')
#15 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(438): Zend\ServiceManager\ServiceManager->createFromFactory('doctrine.entity...', 'zfcuser_doctrin...')
#16 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(391): Zend\ServiceManager\ServiceManager->create(Array)
#17 vendor\zf-commons\zfc-user-doctrine-orm\Module.php(51): Zend\ServiceManager\ServiceManager->get('zfcuser_doctrin...')
#18 [internal function]: ZfcUserDoctrineORM\{closure}(Object(Zend\ServiceManager\ServiceManager), 'zfcuserusermapp...', 'zfcuser_user_ma...')
#19 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(672): call_user_func(Object(Closure), Object(Zend\ServiceManager\ServiceManager), 'zfcuserusermapp...', 'zfcuser_user_ma...')
#20 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(765): Zend\ServiceManager\ServiceManager->createServiceViaCallback(Object(Closure), 'zfcuserusermapp...', 'zfcuser_user_ma...')
#21 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(438): Zend\ServiceManager\ServiceManager->createFromFactory('zfcuserusermapp...', 'zfcuser_user_ma...')
#22 vendor\zendframework\zendframework\library\Zend\ServiceManager\ServiceManager.php(391): Zend\ServiceManager\ServiceManager->create(Array)
#23 vendor\zf-commons\zfc-user\src\ZfcUser\Controller\UserController.php(57): Zend\ServiceManager\ServiceManager->get('zfcuser_user_ma...')
#24 vendor\zendframework\zendframework\library\Zend\Mvc\Controller\AbstractActionController.php(137): ZfcUser\Controller\UserController->loginAction()
#25 [internal function]: Zend\Mvc\Controller\AbstractActionController->execute(Object(Zend\Mvc\MvcEvent))
#26 vendor\zendframework\zendframework\library\Zend\EventManager\EventManager.php(453): call_user_func(Array, Object(Zend\Mvc\MvcEvent))
#27 vendor\zendframework\zendframework\library\Zend\EventManager\EventManager.php(193): Zend\EventManager\EventManager->triggerListeners('dispatch', Object(Zend\Mvc\MvcEvent), Object(Closure))
#28 vendor\zendframework\zendframework\library\Zend\Mvc\Controller\AbstractActionController.php(104): Zend\EventManager\EventManager->trigger('dispatch', Object(Zend\Mvc\MvcEvent), Object(Closure))
#29 vendor\zendframework\zendframework\library\Zend\Mvc\DispatchListener.php(139): Zend\Mvc\Controller\AbstractActionController->dispatch(Object(Zend\Http\PhpEnvironment\Request), Object(Zend\Http\PhpEnvironment\Response))
#30 [internal function]: Zend\Mvc\DispatchListener->onDispatch(Object(Zend\Mvc\MvcEvent))
#31 vendor\zendframework\zendframework\library\Zend\EventManager\EventManager.php(453): call_user_func(Array, Object(Zend\Mvc\MvcEvent))
#32 vendor\zendframework\zendframework\library\Zend\EventManager\EventManager.php(193): Zend\EventManager\EventManager->triggerListeners('dispatch', Object(Zend\Mvc\MvcEvent), Object(Closure))
Ocramius commented 12 years ago

@booradleys can you please describe when this happens?

ghost commented 12 years ago

@Ocramius, It happens when i'm calling /user/login from ZfcUser module (combined with ZfcUserDoctrineORM module).

Ocramius commented 12 years ago

@booradleys please open an issue at https://github.com/ZF-Commons/ZfcUserDoctrineORM/issues, this is because something wrong is passed to the authentication adapter. It has to be handled by the Zfc guys