Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Constructor of \Drupal\syslog\Logger\SysLog uses ConfigFactory instead of ConfigFactoryInterface as first argument. This is not good and should be changed to use the interface.
WebProfiler will send in a ConfigFactoryInterface and will fail with the following message:
Recoverable fatal error: Argument 1 passed to Drupal\syslog\Logger\SysLog::__construct() must be an instance of Drupal\Core\Config\ConfigFactory, instance of Drupal\webprofiler\Config\ConfigFactoryWrapper given, called in C:\git\web\files\php\service_container\service_container_prod\6245d249e2f5a37af3c2b392113af3de2f37541dc84154e0669b53f09f771778.php on line 4502 and defined in Drupal\syslog\Logger\SysLog->__construct() (line 50 of core\modules\syslog\src\Logger\SysLog.php).
Drupal\syslog\Logger\SysLog->__construct(Object, Object)
Drupal\Core\DependencyInjection\Container\prod\service_container_prod->getLogger_SyslogService()
Symfony\Component\DependencyInjection\Container->get('logger.syslog')
Drupal\Core\DependencyInjection\Container\prod\service_container_prod->getLogger_FactoryService()
Symfony\Component\DependencyInjection\Container->get('logger.factory')
Drupal\Core\DependencyInjection\Container\prod\service_container_prod->getLogger_Channel_WebprofilerService()
Symfony\Component\DependencyInjection\Container->get('logger.channel.webprofiler')
Drupal\Core\DependencyInjection\Container\prod\service_container_prod->getProfilerService()
Symfony\Component\DependencyInjection\Container->get('profiler')
Drupal\Core\DependencyInjection\Container\prod\service_container_prod->getWebprofiler_ProfilerlistenerService()
Symfony\Component\DependencyInjection\Container->get('webprofiler.profilerlistener')
Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->getListeners('kernel.request')
Symfony\Component\EventDispatcher\Debug\TraceableEventDispatcher->preProcess('kernel.request')
Symfony\Component\EventDispatcher\Debug\TraceableEventDispatcher->dispatch('kernel.request', Object)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1)
Drupal\Core\DependencyInjection\Container\prod\Symfony_Component_HttpKernel_HttpKernel_Proxy->handle(Object, 1, 1)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1)
Drupal\Core\DependencyInjection\Container\prod\Drupal_Core_StackMiddleware_Session_Proxy->handle(Object, 1, 1)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1)
Drupal\Core\DependencyInjection\Container\prod\Drupal_Core_StackMiddleware_KernelPreHandle_Proxy->handle(Object, 1, 1)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1)
Drupal\devel\StackMiddleware\DevelMiddleware->handle(Object, 1, 1)
Drupal\webprofiler\StackMiddleware\WebprofilerMiddleware->handle(Object, 1, 1)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1)
Stack\StackedHttpKernel->handle(Object, 1, 1)
Drupal\Core\DrupalKernel->handle(Object)
Comment | File | Size | Author |
---|---|---|---|
#1 | syslog_is_incompatible-2498269-1.patch | 1.18 KB | willzyx |
Comments
Comment #1
willzyx CreditAttribution: willzyx commentedyes this should be changed to use the interface (see also Drupal Object-oriented code)
Comment #2
tstoecklerAwesome. This is a bug without disruption, so this is in the hope that no elaborate beta evaluation is needed.
Comment #3
dawehner+1 In an ideal world we would have automatic code review tools which finds those problems
Comment #4
hnygard CreditAttribution: hnygard as a volunteer commentedComment #5
alexpottThis issue is a normal bug fix, and doesn't include any disruptive changes, so it is allowed per https://www.drupal.org/core/beta-changes. Committed 767aa76 and pushed to 8.0.x. Thanks!