Redesign of symfony exceptions
The latest beta changes the look and content of the exceptions thrown by symony.
Up to now, when an exception occurred, it was sometimes difficult to use it to actually find the problem. Here is what the exception used to look like.
Now, the stack trace shows the PHP code (with syntax highlighting) that lead to the exception, making it much easier to find a bug. The arguments that were passed to the methods are also shown. The overall design of the exception pages was completely rebuilt, to have a lighter page layout.
The stack trace is also displayed if an exception is raised by a library that is not part of symfony.
Finally, when you run a symfony app in a non-debug mode, the exceptions are not shown anymore. Instead, the framework returns an Internal Server Error (status code 500) that you can customize by creating a 'error500.html' file in your web/ folder. This is much safer for your code, and much better for your users.
Redesign of symfony exceptions symfony.com/index.php/blog/redesign-of-symfony-exceptionsTweet this
Become a certified developer! Exams are online and available in all countries.Register Now
Comments are closed.
To ensure that comments stay relevant, they are closed for old posts.