File tree 3 files changed +14
-5
lines changed
3 files changed +14
-5
lines changed Original file line number Diff line number Diff line change 1
1
from app import db
2
2
from app .errors import bp
3
3
from flask import render_template
4
+ import traceback
4
5
5
6
6
7
@bp .app_errorhandler (404 )
@@ -27,7 +28,13 @@ def internal_error(error):
27
28
str: HTML page for error 500.
28
29
"""
29
30
db .session .rollback ()
30
- return render_template ("500.html" ), 500
31
+ # Capture the exception details
32
+ traceback_info = traceback .format_exc ()
33
+
34
+ return (
35
+ render_template ("500.html" , traceback_info = traceback_info ),
36
+ 500 ,
37
+ )
31
38
32
39
33
40
@bp .app_errorhandler (413 )
Original file line number Diff line number Diff line change 1
1
{% extends "base.html" %} {% block content %}
2
2
< h1 > Error 500: An unexpected error has occurred</ h1 >
3
- < h3 > Please try going to the Standard Vocabulary module and
4
- press "Save tree" to re-generate files and use this function again !</ h3 >
3
+ < p > If this happened in the visualisation module, a common fix could be going to the Standard Vocabulary module and
4
+ press "Save tree" to re-generate files !</ p >
5
5
< p > The administrator has been notified. Sorry for the inconvenience!</ p >
6
6
< p >
7
7
Please press the back button to go to the index:
8
8
< a href ="{{ url_for('index.index') }} "> Back</ a >
9
9
</ p >
10
- {% endblock %}
10
+ < h3 > Traceback: </ h5 >
11
+ < pre > {{ traceback_info }}</ pre >
12
+ {% endblock %}
Original file line number Diff line number Diff line change 1
1
[tool .poetry ]
2
2
name = " impatient"
3
- version = " 1.6.0 "
3
+ version = " 1.6.1 "
4
4
description = " IMPatienT: an integrated web application to digitize, process and explore multimodal patient data"
5
5
authors = [
" Corentin Meyer <[email protected] >" ]
6
6
license = " AGPL"
You can’t perform that action at this time.
0 commit comments