matomo-org / plugin-PiwikDebugger

Debug and troubleshoot a Matomo server or a plugin with this useful plugin toolkit
GNU General Public License v3.0
3 stars 6 forks source link

Detailed information in case of an exception #8

Open tsteur opened 10 years ago

tsteur commented 10 years ago

Not sure if we actually need it but just noticed this library and it might be useful:

http://filp.github.io/whoops/

Demo: http://filp.github.io/whoops/demo/

tsteur commented 10 years ago

I tried to integrate it in the plugin but it is not really doable. We would need to integrate it in core which could be pretty helpful but only if development mode is enabled. We would benefit of much more information in case of an exception which lets you find issues easier. I've seen and used this tool in many other libraries/frameworks and it is really helpful. Especially for third party developers where you don't have so much knowledge about the code base.

In core we would probably have to pass exceptions to Piwik_ExitWithMessage and if development mode is enabled throw the exception again so whoops can handle it.

Any opinions on that?