-
Notifications
You must be signed in to change notification settings - Fork 30
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
improve error handling #2
Comments
This might be a useful half measure. However, the full solution (translate werkzeug traceback so that the interactive debugger shows proper source, variables, etc) has been committed already (see 0b53723). This requires a minor change to werkzeug (see pallets/werkzeug#206) that hasn't been committed yet. |
Sorry to see this issue stalled for so long, this would be such a huge improvement!! Even if just the "half-measure" above were added. @AnIrishDuck, looks like your PR was just a testcase and changelog entry away from getting merged, but it never happened (see pallets/werkzeug#206 (comment)). Are you still interested in this? And are you, @benselme, still maintaining this project? I'd be happy to help with the remaining work, but first just want to ask how realistic it is that this will get any attention here and make it into a new release soon. Thanks! |
Just applied the changes from https://github.com/mitsuhiko/werkzeug/pull/206/files to Werkzeug manually and it looks like flask-mako needs no further modification for this to work, amazing! In that case, if my comment pallets/werkzeug#206 (comment) gets a response from the Werkzeug maintainers soon, I can volunteer to do the last bit of work to get that merged into Werkzeug, if you don't beat me to it. |
I'm not really maintaining anything here but I'll be happy to make a release if it helps ! |
Thanks @benselme! Fortunately it looks like all it will take before this issue can be closed is pallets/werkzeug#206 to be merged; flask-mako already has what it needs thanks to @AnIrishDuck's 0b53723. But great you're still able to make new releases! Looks like it's been 2 years since the last release, and since then #8 and #9 were fixed/added, so might be worth making a new release now? |
Problem
Currently, all mako exceptions are intercepted and wrapped by the TemplateError.
This is not too useful as the mako error messages are suppressed and the stack trace is not provided in an easily readable presentation.
Template errors will typically be dumped onto the browser to allow easy navigation of the call stack
Suggestion
Expose the underlying Mako errors as a callableTemplateError returning the stack trace as HTML.
Changes are shown below, with the extra imports
The text was updated successfully, but these errors were encountered: