TiuTalk/HtmlTidyComponent — Issue #2: Exceptions X Errors
Author: TiuTalk
Created: 2011-12-02 10:14:14+00:00
State: open

Throwing exceptions (again, in the constructor) means it doesn't degrade gracefully. It works as designed or if flat out kills your application - that's not good. What happens to your application when you deploy or upgrade to your production server and tidy isn't/is-no-longer available?

(...)

Throw exceptions when you try to use code and it won't work without addressing "the problem". Trigger errors when you try to use code and some recoverable problem occurs - That doesn't break your app but it does put "Tidy is configured to clean up your shitty html - but the extension isn't available" into the error log which devs (should) read.