1

I was using Drupal 8.7.7 and decided to update it to 8.8.1. After that the back-end side of the site isn't working anymore, I can only access the site as an anonymous user. The error I get is:

Route "entity.path_alias.collection" does not exist

As suggested by the release notes, I first updated Pathauto to 1.6, then Drupal Core. I ran database updates via update.php and/or drush to no luck. As a result, after rolling back the Drupal core version to 8.7.7, in some admin pages I see this warning:

User warning: The following module is missing from the file system: path_alias in drupal_get_filename() (line 277 of core\includes\bootstrap.inc).

But this warning is not the issue. I want to be running Drupal 8.8.x, not 8.7.7

Here is the full error:

The website encountered an unexpected error. Please try again later.
Symfony\Component\Routing\Exception\RouteNotFoundException: Route "entity.path_alias.collection" does not exist. in Drupal\Core\Routing\RouteProvider->getRouteByName() (line 208 of core\lib\Drupal\Core\Routing\RouteProvider.php).
Drupal\path\Routing\RouteProcessor->processOutbound('path.admin_overview', Object, Array, Object) (Line: 52)
Drupal\Core\RouteProcessor\RouteProcessorManager->processOutbound('path.admin_overview', Object, Array, Object) (Line: 405)
Drupal\Core\Routing\UrlGenerator->processRoute('path.admin_overview', Object, Array, Object) (Line: 292)
Drupal\Core\Routing\UrlGenerator->generateFromRoute('path.admin_overview', Array, Array, 1) (Line: 105)
Drupal\Core\Render\MetadataBubblingUrlGenerator->generateFromRoute('path.admin_overview', Array, Array, 1) (Line: 754)
Drupal\Core\Url->toString(1) (Line: 174)
Drupal\Core\Utility\LinkGenerator->generate('URL aliases', Object) (Line: 63)
Drupal\Core\Utility\LinkGenerator->generateFromLink(Object) (Line: 138)
Drupal\Core\Link->toString() (Line: 29)
template_preprocess_admin_block_content(Array, 'admin_block_content', Array) (Line: 287)
Drupal\Core\Theme\ThemeManager->render('admin_block_content', Array) (Line: 431)
Drupal\Core\Render\Renderer->doRender(Array, ) (Line: 200)
Drupal\Core\Render\Renderer->render(Array) (Line: 501)
Drupal\Core\Template\TwigExtension->escapeFilter(Object, Array, 'html', NULL, 1) (Line: 74)
__TwigTemplate_8048c6546ef7176b663c0cb00ee6d78265ecf31a4f6ee21d14e7d0d942b93fe8->doDisplay(Array, Array) (Line: 455)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 422)
Twig\Template->display(Array) (Line: 434)
Twig\Template->render(Array) (Line: 64)
twig_render_template('core/themes/stable/templates/admin/admin-block.html.twig', Array) (Line: 384)
Drupal\Core\Theme\ThemeManager->render('admin_block', Array) (Line: 431)
Drupal\Core\Render\Renderer->doRender(Array, ) (Line: 200)
Drupal\Core\Render\Renderer->render(Array) (Line: 501)
Drupal\Core\Template\TwigExtension->escapeFilter(Object, Array, 'html', NULL, 1) (Line: 75)
__TwigTemplate_79c329774294b89c8d91701568a3e8e91609085c38e3ab9532cabc063ddee645->doDisplay(Array, Array) (Line: 455)
Twig\Template->displayWithErrorHandling(Array, Array) (Line: 422)
Twig\Template->display(Array) (Line: 434)
Twig\Template->render(Array) (Line: 64)
twig_render_template('core/themes/stable/templates/admin/admin-page.html.twig', Array) (Line: 384)
Drupal\Core\Theme\ThemeManager->render('admin_page', Array) (Line: 431)
Drupal\Core\Render\Renderer->doRender(Array, ) (Line: 200)
Drupal\Core\Render\Renderer->render(Array, ) (Line: 226)
Drupal\Core\Render\MainContent\HtmlRenderer->Drupal\Core\Render\MainContent\{closure}() (Line: 573)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 227)
Drupal\Core\Render\MainContent\HtmlRenderer->prepare(Array, Object, Object) (Line: 117)
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: 111)
Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch('kernel.view', Object) (Line: 156)
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: 694)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
6
  • 1
    The error might suggest that the upgrade to pathauto before the core upgrade didn't go successfully. Restore from backup and try again (there's a chance you've lost data if that update failed, so trying to fix your current installation might not be the best idea). Update pathauto first, then run db updates and clear cache, and only update drupal once that has been confirmed successful
    – Clive
    Dec 30 '19 at 14:08
  • This is what I did. I updated Pathauto, updated database and then updated Core
    – Mantas
    Dec 30 '19 at 14:09
  • 3
    Sounds like the database update failed, see drupal.org/project/pathauto/issues/3096531 for the details
    – Clive
    Dec 30 '19 at 14:11
  • Just enable path_alias core module, drush en path_alias -y
    – berramou
    Dec 30 '19 at 15:09
  • @berramou my man this worked. Thanks!
    – Mantas
    Dec 31 '19 at 10:58
3

Upgrading and downgrading a site is not very well supported unless you also roll back the database.

It seems this should help:

  1. Update pathauto to the latest version.
  2. Run the database updates.
  3. Update again to Drupal 8.8.
  4. Run the database updates.
  5. Ensure the path alias module is installed/enabled.
1
  • 1
    I did everything except for 5. Probably path_alias module wasn't enabled so I enabled it and now everything seems to be working correctly! Thanks
    – Mantas
    Dec 31 '19 at 11:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.