Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
tev
plugin_event
Commits
421aaf3c
Commit
421aaf3c
authored
Mar 31, 2017
by
LE GAC Renaud
Browse files
Update plugin_event controllers in order to show traceback in case of error.
parent
d8e071db
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
controllers/plugin_event.py
controllers/plugin_event.py
+5
-5
No files found.
controllers/plugin_event.py
View file @
421aaf3c
...
...
@@ -2,10 +2,10 @@
"""plugin_event controllers
"""
import
traceback
import
urllib
from
plugin_dbui
import
INLINE_ALERT
from
plugin_event
import
Graph
,
List
,
Metric2D
,
ReportException
...
...
@@ -26,8 +26,8 @@ def grid():
grid
=
report
.
get_grid_configuration
()
title
=
report
.
get_title
()
except
(
IndexError
,
ReportException
,
TypeError
,
ValueError
)
as
e
:
return
INLINE_ALERT
%
(
"REPORT Error..."
,
e
)
except
(
IndexError
,
ReportException
,
TypeError
,
ValueError
):
return
CODE
(
traceback
.
format_exc
()).
xml
(
)
response
.
view
=
"plugin_event/grid.html"
return
dict
(
cfg_store
=
store
,
grid
=
grid
,
title
=
title
)
...
...
@@ -79,5 +79,5 @@ def metric2d():
response
.
view
=
"plugin_event/graph.png"
return
dict
(
data
=
data
,
title
=
title
)
except
(
IndexError
,
ReportException
,
TypeError
,
ValueError
)
as
e
:
return
INLINE_ALERT
%
(
"REPORT Error..."
,
e
)
except
(
IndexError
,
ReportException
,
TypeError
,
ValueError
):
return
CODE
(
traceback
.
format_exc
()).
xml
(
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment