You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@trigger_error(sprintf('As of 3.1 an %s is used to resolve arguments. In 4.0 the $argumentResolver becomes the %s if no other is provided instead of using the $resolver argument.', ArgumentResolverInterface::class, ArgumentResolver::class), E_USER_DEPRECATED);
@@ -67,6 +71,15 @@ public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQ
67
71
try {
68
72
return$this->handleRaw($request, $type);
69
73
} catch (\Exception$e) {
74
+
if ($this->container && $einstanceof ServiceNotFoundException) {
75
+
$id = $e->getId();
76
+
77
+
if (!$e->getSourceId() && ($this->container->has($id) || isset($this->container->getRemovedIds()[$id]))) {
78
+
$r = new \ReflectionProperty(\Exception::class, 'message');
79
+
$r->setAccessible(true);
80
+
$r->setValue($e, sprintf('Service "%s" exists, but not in the service locator of your own service. Did you forget to declare it as a dependency using e.g. "ServiceSubscriberInterface::getSubscribedServices()"?', $id));
0 commit comments