Problem/Motivation
The website encountered an unexpected error. Please try again later.
TypeError: Argument 1 passed to Drupal\counter\EventSubscriber\CounterEventsSubscriber::counterInsert() must be an instance of Symfony\Component\HttpKernel\Event\RequestEvent, instance of Symfony\Component\HttpKernel\Event\GetResponseEvent given in Drupal\counter\EventSubscriber\CounterEventsSubscriber->counterInsert() (line 76 of modules/contrib/counter/src/EventSubscriber/CounterEventsSubscriber.php).
Drupal\counter\EventSubscriber\CounterEventsSubscriber->counterInsert(Object, 'kernel.request', Object)
call_user_func(Array, Object, 'kernel.request', Object) (Line: 111)
Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch('kernel.request', Object) (Line: 127)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 708)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
Getting the above error on installing the module.
Comment | File | Size | Author |
---|---|---|---|
#7 | counter-cant-install-on-drupal-8-9-13-3322360-7.patch | 1.18 KB | goyalsushant |
Comments
Comment #2
ayush.khare CreditAttribution: ayush.khare at OpenSense Labs for DrupalFit commentedComment #3
kartiktandon CreditAttribution: kartiktandon as a volunteer and at TO THE NEW commentedComment #4
kartiktandon CreditAttribution: kartiktandon as a volunteer and at TO THE NEW commentedComment #5
goyalsushant CreditAttribution: goyalsushant as a volunteer and at TO THE NEW commentedI am working on it.
Comment #6
goyalsushant CreditAttribution: goyalsushant as a volunteer and at TO THE NEW commentedComment #7
goyalsushant CreditAttribution: goyalsushant as a volunteer and at TO THE NEW commentedPlease find the attached patch for the issue.
This patch only works for Drupal version 8.8.x and 8.9.x
Kindly note since the Symfony versions are different for Drupal 8 and 9, this issue comes up. The Symfony version used in Drupal 8.x is Symfony 3.x and Drupal 9.x is Symfony 4.4+
Comment #8
ayush.khare CreditAttribution: ayush.khare at OpenSense Labs for DrupalFit commented