-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[Debug] Design tweaks #11341
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
It looks better to me, and there's no downside I can think of. If someone wants to try to tweak this and make a PR, that would be awesome! |
Can someone explain which files need to be modified and when they are used? From a quick search I noticed that there are a lot of files defining CSS rules for the HTML elements being used here. |
I think error (which is not the normal big nice exception template" is entirely in this file (including the CSS): https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Debug/ExceptionHandler.php Good question @xabbuh :) |
I think @alsar is using an older Symfony version. In Symfony 2.5, I get this: |
@wouterj it depends, early exceptions (before the request) use the debug component for exception handling. |
In fact the first screenshot is from Symfony 2.6-dev (#10921), the second from Symfony 2.5, and @sstok is right: before the request event, the "no color" handler is used, generated by: Then after the request event, the "colored" one is: |
@wouterj the difference is that the standard edition uses TwigBundle which contains different templates than what the Debug component spits out. edit: which is what @nicolas-grekas wrote, damn i need to read before responding. |
@nicolas-grekas so the design actually got worse in the latest Symfony version? That doesn't sound correc to me :)
Wait, sorry. Stupid me, my last paragraph is not true. The location is different and by that, the design is different. I propose to make the design consistent. |
This is how error handling works since 2.3 or 2.4:
This is a bootstrap process: errors can happen before the request event, and we want to see them. But once everything is properly booted, we can have even more sweetness, thus the second handler. There is nothing wrong here. |
This PR was merged into the 2.6-dev branch. Discussion ---------- [Debug] fix and enhance exception messages | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | #11341 | License | MIT | Doc PR | none Commits ------- 8df1ce8 [Debug] fix and enhance exception messages
Fixed in #11759 |
Currently the error message is not very readable in my opinion, because the exception name and the exception message stick together. Also the message is not aligned on the left side if it's spread over multiple lines.
I propose something like this:

Maybe the error message could also be separate section with it's own background.
What do you think?
The text was updated successfully, but these errors were encountered: