Laravel-debugbar: Route debugbar:openhandler not defined

Created on 5 Feb 2015  Â·  19Comments  Â·  Source: barryvdh/laravel-debugbar

I have the following error in the logs and Debugbar doesnt show up:

[2015-02-05 12:02:22] local.ERROR: Debugbar exception: Route [debugbar.openhandler] not defined.  

I have a fresh new L5 install, only laravel-debugbar (v2.0) package added, and published the config file.
Package is enabled, env is local
Am I missing something?

EDIT: in the prev version it was a debugbar folder in the storage folder. Now in L5 there isn't, is it OK?

Most helpful comment

Same issue here. clearing all the cache is fixing the issue for me:
php artisan clear-compiled; php artisan cache:clear; php artisan route:clear

All 19 comments

I'm not sure, it's working for me. Don't know why the route wouln't show up. It should just register it here: https://github.com/barryvdh/laravel-debugbar/blob/master/src/ServiceProvider.php#L36

If you guide me I can debug it, of course if you're interested in.

Eh, it's a bit hard to guide because I don't know what causing it :P

I would use dd() driven debugging ;) Put a dd('in boot') in the start of the boot, and see if it boots and get's to the router part (https://github.com/barryvdh/laravel-debugbar/blob/master/src/ServiceProvider.php#L36)

You could also disable the storage, see if that helps (storage.enabled)

  • the package boots up well
  • disabling storage option doesn't make it work
    The $this->app['route'] content is:
Router {#22 â–¼
  #events: Dispatcher {#5 â–¶}
  #container: Application {#2 â–¶}
  #routes: RouteCollection {#24 â–¼
    #routes: array:2 [â–¶]
    #allRoutes: array:3 [â–¼
      "HEAD_debugbar/open" => Route {#94 â–¶}
      "HEAD_debugbar/assets/stylesheets" => Route {#95 â–¶}
      "HEAD_debugbar/assets/javascript" => Route {#96 â–¶}
    ]
    #nameList: array:3 [â–¶]
    #actionList: array:3 [â–¼
      "Barryvdh\Debugbar\Controllers\OpenHandlerController@handle" => Route {#94 â–¶}
      "Barryvdh\Debugbar\Controllers\AssetController@css" => Route {#95 â–¶}
      "Barryvdh\Debugbar\Controllers\AssetController@js" => Route {#96 â–¶}
    ]
  }
  #current: null
  #currentRequest: null
  #middleware: array:3 [â–¶]
  #patternFilters: []
  #regexFilters: []
  #binders: []
  #patterns: []
  #groupStack: []
}

so the routes are added , too.
Np Barry, time solves lot of things :)

EDIT: setting _inject_ to _false_ - no error in the log file. Maybe that helps..

Can you clear the storage folders? Perhaps the routes are cached, or the service provider manifests or something.

Cleared storage folders/subfolders but nothing new

EDIT: talked with a guy on IRC if he installs and works for him, let me know. If he's all right, then the error is in my system/install/whatever...

Ok, so the guy installed successfully. I changed APP_DEBUG in .env to false, refreshed screen, changed to back to true, and at the end set inject option again to true, now WORKS. I can't find any reason what happened..
sorry for that Barry, thank you for your time

Probably something being cached or something

I don't know if .env is cached but will investigate

EDIT: Possibly I installed yesterday L5 too early, because I had already a .env file in there, not only .env.example

Last comment, i forget to say meantime i fired a composer update, and it was a change:

barna@barna:/var/www/laravel5⟫ composer update
Loading composer repositories with package information
Updating dependencies (including require-dev)
  - Removing maximebf/debugbar (v1.10.3)
  - Installing maximebf/debugbar (v1.10.4)
    Downloading: 100%  

could be the reason? who knows..

Shouldn't have anything to do with it, as far I know.

Strange, I am having the exact same problem. Nothing appearing in the browser and the same error message in the log. Tried it now in the latest version of Firefox, Chrome and IE but none of the browsers displays the debugbar. Also repeated the steps that resolved the issue for subdesign but to no avail. Any suggestions?

I had the same issue and none of the mentioned solutions were working. What did the trick for me was to run php artisan clear-compiled

Does not seem to work for me. In my case it seems to have more to do with the browser. I created a new project, started from scratch and now the debugbar does appear, but only for this app. In the old app the debugbar stays hidden. Clearing the browser history completely did not help.

I am also having this issue. I have my routes cached but i cleared it and recached and debugbar.openhandler is STILL not showing up in the route list....doesn't show up on the page ... APP_DEBUG=true....error shows up in logs

Same issue here. clearing all the cache is fixing the issue for me:
php artisan clear-compiled; php artisan cache:clear; php artisan route:clear

Just experienced the same problem. Clearing the route cache fixed it for me.

I can confirm that using cached routes generated the issue.

Same happened to me... I think this problem shows up when you have APP_DEBUG=false and run php artisan route:cache. Then you switch APP_DEBUG to true and there is this error. When I run route:cache with APP_DEBUG=true everything works fine...

Was this page helpful?
0 / 5 - 0 ratings

Related issues

alphametric picture alphametric  Â·  5Comments

ddmo picture ddmo  Â·  3Comments

damienfern picture damienfern  Â·  4Comments

kjhatis picture kjhatis  Â·  5Comments

lucasdcrk picture lucasdcrk  Â·  3Comments