Currently, if an exception is thrown when generating a block, a huge horrible fatal error is generated. Really we don't need to have anything quite that exotic. Why don't we put a try/catch around the block generation and not render the block (and emit a regular _drupal_log_error() or something) so that the administrator gets the information, but we don't deliver a full fatal error for every page where the block is to be rendered.

Comments

damien tournoud’s picture

Status: Active » Needs review
StatusFileSize
new2.39 KB

Suggested patch.

rfay’s picture

Title: Catch exceptions when building all blocks » Catch exceptions for render/entity failures
StatusFileSize
new7.6 KB

Working the queue, I notice the other place that's crucial in this regard is rendering a product reference. This patch adds a try/catch around the product reference view in commerce_product_reference.

rfay’s picture

We really really still need to handle this situation.

rfay’s picture

Status: Needs review » Needs work

Doesn't apply any more and the merge requires brainwork. Marking CNW

jsacksick’s picture

Issue summary: View changes
Status: Needs work » Closed (outdated)