-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ASP.NET Core 2 middleware error handling #48
Comments
Hello, Mads! This issue has been discussed many times (for example, “drop minification in case of errors”). Just nobody reads the documentation. |
I did read it, but I don't know how to use the NullLogger. Any code samples? |
The NullLogger fixes the issue with the original repro step. However, add the following to any HTML reponse and it breaks again:
|
Also, another issue with the |
Never mind. I got confused by the names |
Hello, Mads!
This error is handled correctly.
Unfortunately, I began to use such type names still in 2013.
In next release I will make |
When the HTML is malformed leading to an HTML parse error inside the WebMarkupMin middleware, there is no way to gracefully handle it.
Repro steps
<br
tag anywhere on the pageActual
The middleware throws an exception and the page is therefore not shown - but instead an error message is displayed if no custom error page is defined.
Expected
When an error occurs, simple just about the minification and serve the unminified. That way the page isn't broken and the user can see the content
The text was updated successfully, but these errors were encountered: