Problem/Motivation

I can verify as mentioned by markdc and SirClickALot in an unrelated issue that Link Trail by Path is causing the following error:

InvalidArgumentException: Route required in Drupal\Core\Url::fromRouteMatch() (line 167 of /home/<...>/public_html/core/lib/Drupal/Core/Url.php)
#0 /home/<...>/public_html/modules/link_trail_by_path/link_trail_by_path.module(51): Drupal\Core\Url::fromRouteMatch(Object(Drupal\Core\Routing\CurrentRouteMatch))
#1 /home/<...>/public_html/core/lib/Drupal/Core/Theme/ThemeManager.php(287): link_trail_by_path_preprocess_links(Array, 'links', Array)
#2 /home/<...>/public_html/core/lib/Drupal/Core/Render/Renderer.php(431): Drupal\Core\Theme\ThemeManager->render('links', Array)
#3 /home/<...>/public_html/core/lib/Drupal/Core/Render/Renderer.php(200): Drupal\Core\Render\Renderer->doRender(Array, true)
#4 /home/<...>/public_html/core/lib/Drupal/Core/Render/Renderer.php(156): Drupal\Core\Render\Renderer->render(Array, true)
#5 /home/<...>/public_html/core/lib/Drupal/Core/Render/Renderer.php(573): Drupal\Core\Render\Renderer->Drupal\Core\Render\{closure}()
#6 /home/<...>/public_html/core/lib/Drupal/Core/Render/Renderer.php(157): Drupal\Core\Render\Renderer->executeInRenderContext(Object(Drupal\Core\Render\RenderContext), Object(Closure))
#7 /home/<...>/public_html/core/lib/Drupal/Core/Render/Renderer.php(171): Drupal\Core\Render\Renderer->renderPlain(Array)
#8 /home/<...>/public_html/core/modules/big_pipe/src/Render/BigPipe.php(693): Drupal\Core\Render\Renderer->renderPlaceholder('callback=user.t...', Array)
#9 /home/<...>/public_html/core/modules/big_pipe/src/Render/BigPipe.php(547): Drupal\big_pipe\Render\BigPipe->renderPlaceholder('callback=user.t...', Array)
#10 /home/<...>/public_html/core/modules/big_pipe/src/Render/BigPipe.php(305): Drupal\big_pipe\Render\BigPipe->sendPlaceholders(Array, Array, Object(Drupal\Core\Asset\AttachedAssets))
#11 /home/<...>/public_html/core/modules/big_pipe/src/Render/BigPipeResponse.php(112): Drupal\big_pipe\Render\BigPipe->sendContent(Object(Drupal\big_pipe\Render\BigPipeResponse))
#12 /home/<...>/public_html/vendor/symfony/http-foundation/Response.php(374): Drupal\big_pipe\Render\BigPipeResponse->sendContent()
#13 /home/<...>/public_html/index.php(20): Symfony\Component\HttpFoundation\Response->send()
#14 {main}

Steps to reproduce

  1. Enable Link Trail by Path and core Database Logging modules.
  2. Create node or taxonomy entities using paths existing in a hierarchy, containing links to pages in the path hierarchy a described on the project page.
  3. Run cron
  4. Visit admin and/or content pages.
  5. Check logs and look for PHP error "User error: InvalidArgumentException: Route required".

I'm creating this as a separate issue since #2918474 is focused on Link Trail by Path not working on Views with caching enabled.

Comments

caldenjacobs created an issue. See original summary.

pol’s picture

Hello,

I'm not using Drupal anymore, so I don't maintain this module anymore either.

However, I'm accepting patches and I will commit them if necessarily.

Thanks!

caldenjacobs’s picture

Thanks, Pol!

caldenjacobs’s picture

Issue summary: View changes