sonata-project/SonataBlockBundle — pull request #40 by oparadis (2012-12-19 16:27:24+00:00)
Title: Feature: exception strategy management (updated)

Currently, when not in debug mode, exceptions thrown in block services are completely ignored and are converted in blank blocks (no html). This may lead to unexpected behaviors in production since the page could end up being partially rendered.

In debug mode, all exceptions are thrown and managed by the framework with a full exception page. While the exception page is handy, it only shows the first exception encountered and hides the block composition of the page. This can sometimes be confusing if you want to have a more global view of the problems encountered on a page.

This feature proposes to implement an exception strategy management in order to give control on how exceptions thrown by block services should be managed.

The aim is to handle all exceptions thrown by block services, identify which exceptions should be managed with "exception filters", and show the exceptions through "exception renderers". Filters and renderers can be configured globally or on a per block-type basis, and it is easy to add new custom filters or custom renderers.

UPDATED:
* Fixed configuration issues: works out of the box.