- Issue created by @yazzbe
- π§πͺBelgium yazzbe
Found the cause of the error in my menu--navbar.html.twig file.
This code was causing an issue after running update.php{% if item.url.routeName == "<front>" %}
Removed it from my custom theme to get the site working again.
Don't know if this it related to the latest drupal 10.4.45 update. - π§πͺBelgium yazzbe
Bumping this to major since it is a breaking change (WSOD).
I think it should be still possible to use item.url.routeName == "" in a twig menu template, without breaking the site after running update.php
- π¬π§United Kingdom catch
Which version of core did you update from?
Also there's no 10.4.45 do you mean 10.4.5?
- π¬π·Greece vensires
The my menu--navbar.html.twig file phrase in #3 confused me; I'm changing this to a support request.
Feel free to revert my change in case I was mistaken. - π§πͺBelgium yazzbe
Ok fine.
The update was from D10.4.3 to 10.4.5
Iβll try to work around and not use
item.url.routeName == "<front>"
anymore in Twig templates.This is possibly breaking after the security fix and sanitization of link attributes in the latest security release.
- π¬π§United Kingdom catch
This is the error in the issue summary:
UnexpectedValueException: base:regions has no corresponding route. in Drupal\Core\Url->getRouteName() (line 567 of /data/sites/web/site/www/core/lib/Drupal/Core/Url.php).
Have you checked your code base for
base:regions
? I very much doubt this is actually about the<front>
route because there'd be a lot more bug reports. - π§πͺBelgium yazzbe
I was eventually able to update the site.
When creating a menu link, I usually type the relative path directly into the link field β but that field is actually an autosuggest field.
When using the autosuggest (instead of entering the path manually), the custom menu Twig template no longer throws an error.
So, itβs probably better not to enter the menu path manually, but to let Drupal set the lmenu ink by selecting a value from the autosuggest.