wingsuit-designsystem / wingsuit

Twig for Storybook
GNU General Public License v2.0
90 stars 16 forks source link

Drupal\Component\Plugin\Exception\PluginNotFoundException: The "container" plugin does not exist. #268

Closed finnlewis closed 1 year ago

finnlewis commented 1 year ago

Describe the bug

Enabling the generated wingsuit theme in Drupal and trying to browse the front end of the site is generating the following error.

Drupal\Component\Plugin\Exception\PluginNotFoundException: The "container" plugin does not exist. Valid plugin IDs for Drupal\ui_patterns\UiPatternsManager are: in Drupal\Core\Plugin\DefaultPluginManager->doGetDefinition() (line 53 of core/lib/Drupal/Component/Plugin/Discovery/DiscoveryTrait.php).

Drupal\Core\Plugin\DefaultPluginManager->getDefinition('container') (Line: 42)
Drupal\ui_patterns\UiPatterns::getPatternDefinition('container') (Line: 50)
Drupal\ui_patterns_settings\TwigExtension\UIPatternsSettingsExtension->patternConfiguration('container', '', 'bg') (Line: 60)
__TwigTemplate_07997f850622e867983230250c2c9882->doDisplay(Array, Array) (Line: 405)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 378)
Twig\Template->display(Array, Array) (Line: 167)
__TwigTemplate_14da1083556d0f261df71dbf82ebe284___268816183->doDisplay(Array, Array) (Line: 405)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 378)
Twig\Template->display(Array) (Line: 51)
__TwigTemplate_14da1083556d0f261df71dbf82ebe284->doDisplay(Array, Array) (Line: 405)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 378)
Twig\Template->display(Array) (Line: 72)
__TwigTemplate_78d49907ad03b7d59ae0b08553c79503->block_header(Array, Array) (Line: 182)
Twig\Template->displayBlock('header', Array, Array) (Line: 45)
__TwigTemplate_78d49907ad03b7d59ae0b08553c79503->doDisplay(Array, Array) (Line: 405)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 378)
Twig\Template->display(Array, Array) (Line: 210)
__TwigTemplate_6fe52d3c3d9cae9569e4a15f59dc152a___301449030->doDisplay(Array, Array) (Line: 405)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 378)
Twig\Template->display(Array) (Line: 58)
__TwigTemplate_6fe52d3c3d9cae9569e4a15f59dc152a->doDisplay(Array, Array) (Line: 405)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 378)
Twig\Template->display(Array) (Line: 390)
Twig\Template->render(Array) (Line: 55)
twig_render_template('themes/custom/wingsuit/apps/drupal/templates/layout/page.html.twig', Array) (Line: 384)
Drupal\Core\Theme\ThemeManager->render('page', Array) (Line: 433)
Drupal\Core\Render\Renderer->doRender(Array, ) (Line: 204)
Drupal\Core\Render\Renderer->render(Array) (Line: 479)
Drupal\Core\Template\TwigExtension->escapeFilter(Object, Array, 'html', NULL, 1) (Line: 76)
__TwigTemplate_c32b8117d9f636308966182ae471499f->doDisplay(Array, Array) (Line: 405)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 378)
Twig\Template->display(Array) (Line: 390)
Twig\Template->render(Array) (Line: 55)
twig_render_template('themes/custom/wingsuit/apps/drupal/templates/layout/html.html.twig', Array) (Line: 384)
Drupal\Core\Theme\ThemeManager->render('html', Array) (Line: 433)
Drupal\Core\Render\Renderer->doRender(Array, ) (Line: 204)
Drupal\Core\Render\Renderer->render(Array) (Line: 162)
Drupal\Core\Render\MainContent\HtmlRenderer->Drupal\Core\Render\MainContent\{closure}() (Line: 580)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 163)
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: 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: 718)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

To Reproduce

Install standard profile of Drupal 9.5.8
PHP version: 8.1.16

cd themes/custom
npx @wingsuit-designsystem/cli@1.2.8 init -k tailwind 
cd wingsuit
yarn build:drupal  
drush en wingsuit_companion wingsuit_ui_patterns

Create a basic page. Install winguit theme and set to default. Browse /node/1 See the error above.

Additional context

I've seen these related issues:

So I've made sure that components is version: 8.x-2.4

finnlewis commented 1 year ago

I've got rid of the error by setting Dist path at /admin/wingsuit-companion/form/config to :

themes/custom/wingsuit/dist/app-drupal

As suggested in https://www.drupal.org/project/wingsuit_companion/issues/3272674#comment-14464364

Is this correct or am I missing something else?

finnlewis commented 1 year ago

Demo site appears to be under maintenance so I can't check the config there: http://demo.wingsuit.dev.key-tec.de/en

jphat commented 1 year ago

hey @finnlewis.

Generate both wingsuit and importantly Drupal files. Clear cache.

also, try: http://demo.wingsuit.dev.key-tec.de/en/user/login

finnlewis commented 1 year ago

See https://github.com/wingsuit-designsystem/wingsuit/issues/267#issuecomment-1557069727 for what works for me on Drupal 9 and the 1.x branch of wingsuit.