Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.6k
Closed
Description
Symfony version(s) affected
7.2.0
Description
When I browse my local website, the debug toolbar is displayed without any style:
Loadinghttp://localhost:8000/_wdt/styles.css
in the browser shows:
The requested resource /_wdt/styles.css was not found on this server.
For some reason, it is passed to the PHP built-in server:
How to reproduce
The PHP server runs in Docker throughphp -S 0.0.0.0:8000 -t public/
.
It looks like it's not the source of the problem sincehttp://localhost:8000/_wdt/50aa18?XDEBUG_IGNORE=1
works without any issue.
Possible Solution
See this workaround to change the path of the path in your project:#59045 (comment)
Additional Context
The debug toolbar has no issues:
Router
config/routes/web_profiler.yaml
when@dev:web_profiler_wdt:resource:'@WebProfilerBundle/Resources/config/routing/wdt.xml'prefix:/_wdtweb_profiler_profiler:resource:'@WebProfilerBundle/Resources/config/routing/profiler.xml'prefix:/_profiler
debug:router
:
$ bin/console debug:router _wdt_stylesheet+--------------+--------------------------------------------------------------------------+| Property | Value |+--------------+--------------------------------------------------------------------------+| Route Name | _wdt_stylesheet || Path | /_wdt/styles.css || Path Regex | {^/_wdt/styles\.css$}sDu || Host | ANY || Host Regex | || Scheme | ANY || Method | ANY || Requirements | NO CUSTOM || Class | Symfony\Component\Routing\Route || Defaults | _controller: web_profiler.controller.profiler::toolbarStylesheetAction() || Options | compiler_class: Symfony\Component\Routing\RouteCompiler || | utf8: true |+--------------+--------------------------------------------------------------------------+$ bin/console debug:router _wdt+--------------+----------------------------------------------------------------+| Property | Value |+--------------+----------------------------------------------------------------+| Route Name | _wdt || Path | /_wdt/{token} || Path Regex | {^/_wdt/(?P<token>[^/]++)$}sDu || Host | ANY || Host Regex | || Scheme | ANY || Method | ANY || Requirements | NO CUSTOM || Class | Symfony\Component\Routing\Route || Defaults | _controller: web_profiler.controller.profiler::toolbarAction() || Options | compiler_class: Symfony\Component\Routing\RouteCompiler || | utf8: true |+--------------+----------------------------------------------------------------+
Related: