InvalidComponentException when workspaces and workspaces ui is installed

Created on 10 May 2025, 20 days ago

Problem/Motivation

with the latest state of 11.x, a fresh site install with the standard profile (did a drush sql:drop right before), uninstalled the toolbar module and installed the navigation module plus a few more core modules(content moderation, responsive images, media), as soon as i am installing workspaces and workspaces ui i get the following new error:

The website encountered an unexpected error. Try again later.

Drupal\Core\Render\Component\Exception\InvalidComponentException: [navigation:toolbar-button/icon] NULL value found, but an object is required. in Drupal\Core\Theme\Component\ComponentValidator->validateProps() (line 232 of core/lib/Drupal/Core/Theme/Component/ComponentValidator.php).
Drupal\Core\Template\ComponentsTwigExtension->doValidateProps() (Line: 106)
Drupal\Core\Template\ComponentsTwigExtension->validateProps() (Line: 47)
__TwigTemplate_0fe65a4c3914659ea1cbf43cfba3b541->doDisplay() (Line: 388)
Twig\Template->yield() (Line: 151)
__TwigTemplate_820f6accfc70093bd7b1bb2211317ab1->{closure}() (Line: 2079)
Twig\Extension\CoreExtension::captureOutput() (Line: 77)
__TwigTemplate_820f6accfc70093bd7b1bb2211317ab1->macro_menu_items() (Line: 54)
__TwigTemplate_820f6accfc70093bd7b1bb2211317ab1->doDisplay() (Line: 388)
Twig\Template->yield() (Line: 344)
Twig\Template->display() (Line: 359)
Twig\Template->render() (Line: 51)
Twig\TemplateWrapper->render() (Line: 34)
twig_render_template() (Line: 380)
Drupal\Core\Theme\ThemeManager->render() (Line: 493)
Drupal\Core\Render\Renderer->doRender() (Line: 245)
Drupal\Core\Render\Renderer->doRenderRoot() (Line: 141)
Drupal\Core\Render\Renderer->Drupal\Core\Render\{closure}() (Line: 623)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 140)
Drupal\Core\Render\Renderer->renderInIsolation() (Line: 167)
Drupal\Core\Render\Renderer->doRenderPlaceholder() (Line: 725)
Drupal\Core\Render\Renderer->Drupal\Core\Render\{closure}()
Fiber->start() (Line: 733)
Drupal\Core\Render\Renderer->replacePlaceholders() (Line: 256)
Drupal\Core\Render\Renderer->doRenderRoot() (Line: 141)
Drupal\Core\Render\Renderer->Drupal\Core\Render\{closure}() (Line: 623)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 140)
Drupal\Core\Render\Renderer->renderInIsolation() (Line: 167)
Drupal\Core\Render\Renderer->doRenderPlaceholder() (Line: 725)
Drupal\Core\Render\Renderer->Drupal\Core\Render\{closure}()
Fiber->start() (Line: 733)
Drupal\Core\Render\Renderer->replacePlaceholders() (Line: 256)
Drupal\Core\Render\Renderer->doRenderRoot() (Line: 141)
Drupal\Core\Render\Renderer->Drupal\Core\Render\{closure}() (Line: 623)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 140)
Drupal\Core\Render\Renderer->renderInIsolation() (Line: 111)
Drupal\Core\Render\Renderer->renderRoot() (Line: 253)
Drupal\Core\Render\HtmlResponseAttachmentsProcessor->renderPlaceholders() (Line: 74)
Drupal\big_pipe\Render\BigPipeResponseAttachmentsProcessor->processAttachments() (Line: 45)
Drupal\Core\EventSubscriber\HtmlResponseSubscriber->onRespond() (Line: 246)
Symfony\Component\EventDispatcher\EventDispatcher::Symfony\Component\EventDispatcher\{closure}() (Line: 206)
Symfony\Component\EventDispatcher\EventDispatcher->callListeners() (Line: 56)
Symfony\Component\EventDispatcher\EventDispatcher->dispatch() (Line: 216)
Symfony\Component\HttpKernel\HttpKernel->filterResponse() (Line: 204)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle() (Line: 53)
Drupal\Core\StackMiddleware\Session->handle() (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle() (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle() (Line: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->handle() (Line: 116)
Drupal\page_cache\StackMiddleware\PageCache->pass() (Line: 90)
Drupal\page_cache\StackMiddleware\PageCache->handle() (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 53)
Drupal\Core\StackMiddleware\AjaxPageState->handle() (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle() (Line: 715)
Drupal\Core\DrupalKernel->handle() (Line: 19)

the error is gone on ddev drush pmu navigation && ddev drush en toolbar and returns on ddev drush pmu toolbar && ddev drush en navigation. also searched the issue queue but havent found any matches yet.

(on ddev with php 8.3)

Steps to reproduce

  • install the latest version of 11.x
  • install the navigation module
  • install workspaces and workspaces ui

Proposed resolution

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

๐Ÿ› Bug report
Status

Active

Version

11.0 ๐Ÿ”ฅ

Component

workspaces.module

Created by

๐Ÿ‡ฉ๐Ÿ‡ชGermany rkoller Nรผrnberg, Germany

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @rkoller
  • ๐Ÿ‡ฌ๐Ÿ‡งUnited Kingdom catch

    Moving this to navigation module.

  • First commit to issue fork.
  • Merge request !12237fix: use build items instead of menu tree โ†’ (Open) created by Rhezios
  • Pipeline finished with Failed
    4 days ago
    Total: 326s
    #506543
  • ๐Ÿ‡ณ๐Ÿ‡ฑNetherlands Rhezios

    The error is caused by rendering disabled links which are set as build item by \Drupal\navigation\Menu\NavigationMenuLinkTree::build(). By switching from menu tree to $build['items'] we ensure that only items inside the build array are altered

    Patch #5 contains a re-roll against Drupal 11.1

  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia libbna New Delhi, India

    Is the work still is progress? Because I applied the patch and checked, I am still getting the error.

Production build 0.71.5 2024