punch
punch copied to clipboard
Punch could catch LESS parsing errors
When running punch s
it is sometimes annoying that it fully crashes when less parser throws an error. Punch could handle this so that an error page is returned.
I guess this is because you're using an old version of the Less npm module. From 1.4.1, Less module passes the error to callback, instead of raising the exception.
Also, try upgrading to latest Punch (0.5.37 or above), which should log Less parsing errors more descriptively.
I have upgraded to Punch 0.5.37 and Less 1.4.2 and it still fails silently. The generated CSS file is empty and punch s
just returns status 200.
The project where I've got this problem is here: https://github.com/smola/smola.github.io/tree/punch
@laktek I think @smola is describing something like an in browser error page when parsing errors occur versus just logging to the console when template or css errors occur.
For example, here is an error page from the better_errors gem: