No Cors headers sent for 500 errors
gone opened this issue · comments
Ben Beecher commented
This is a minor QOL dev compliant - When doing something stupid in the server, rather than getting a 500 response from the server I get a CORS issue in my client.
Adam Johnson commented
Unfortunately it's not possible to add headers in a middleware to 500 error responses. These are generated by the handler500
view configured in Django, which runs outside the middleware stack :/
I'll keep this in mind for any potential refactoring but closing since it's not possible. Agree it would make development a bit easier.