Problem/Motivation

When i try to edit any view on admin/structure/views I run into the following error:

The website encountered an unexpected error. Please try again later.

LogicException: Cannot push a context collection more than once. in Drupal\context_stack\ContextStack->push() (line 90 of modules/contrib/context_stack/src/ContextStack.php).
Drupal\context_stack_form\Render\FormStack::preRender(Array)
call_user_func_array(Array, Array) (Line: 101)
Drupal\Core\Render\Renderer->doTrustedCallback(Array, Array, 'Render #pre_render callbacks must be methods of a class that implements \Drupal\Core\Security\TrustedCallbackInterface or be an anonymous function. The callback was %s. See https://www.drupal.org/node/2966725', 'exception', 'Drupal\Core\Render\Element\RenderCallbackInterface') (Line: 788)
Drupal\Core\Render\Renderer->doCallback('#pre_render', Array, Array) (Line: 374)
Drupal\Core\Render\Renderer->doRender(Array) (Line: 446)
Drupal\Core\Render\Renderer->doRender(Array, ) (Line: 204)
Drupal\Core\Render\Renderer->render(Array, ) (Line: 242)
Drupal\Core\Render\MainContent\HtmlRenderer->Drupal\Core\Render\MainContent\{closure}() (Line: 580)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 243)
Drupal\Core\Render\MainContent\HtmlRenderer->prepare(Array, Object, Object) (Line: 132)
Drupal\Core\Render\MainContent\HtmlRenderer->renderResponse(Array, Object, Object) (Line: 90)
Drupal\Core\EventSubscriber\MainContentViewSubscriber->onViewRenderArray(Object, 'kernel.view', Object)
call_user_func(Array, Object, 'kernel.view', Object) (Line: 142)
Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch(Object, 'kernel.view') (Line: 174)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 81)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
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: 50)
Drupal\ban\BanMiddleware->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 713)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

On Drupal 9.5.2 and PHP 8.1.13 with ECA 1.1.x-dev@dev, bpmn.io 1.1.x-dev@dev, Context Stack 1.1 and ECA_context 1.0

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Comments

rkoller created an issue. See original summary.

mxh’s picture

Version: 1.1.0 » 1.0.x-dev
Assigned: Unassigned » mxh

Thanks for the detailed bug report. Will have a look at it, hopefully in the near future.

  • 0a4c676d committed on 1.0.x
    Issue #3335435 by rkoller, mxh: WSOD when editing a view
    
mxh’s picture

Assigned: mxh » Unassigned
Status: Active » Fixed

Pushed a fix that's supposed to fix the bug. Will create a new release 1.1.1 that will contain the fix. If the problem still persists, feel free to just re-open this one.

rkoller’s picture

cool! and i've updated context_stack to the latest dev version and i can confirm that the error is fixed.

mxh’s picture

That's great news, thanks for the confirmation.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.