Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

pa2codes's avatar

Telescope Routing error on production with artisan optimize:clear command

Hi Community,

We have a strange error using Telescope on production after running the laravel optimize commands.

When using the optimize:clear command and then rebuild the cache with optimize, we get the following error:

"exception": "[object] (Symfony\Component\Routing\Exception\RouteNotFoundException(code: 0): Route [telescope] not defined. at /var/www/vhosts/ourdomain.de/app.ourdomain.de/releases/351/vendor/laravel/framework/src/Illuminate/Routing/UrlGenerator.php:516)

We are using deployer and the deploy.yaml looks like

  deploy:
    - deploy:prepare
#   ---
    - deploy:vendors
    - artisan:storage:link
    - artisan:optimize:clear
    - artisan:optimize
    ....

If we don't run artisan:optimize:clear its working.

Any ideas?

Thanks

0 likes
0 replies

Please or to participate in this conversation.