Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Jannik Hellenkamp
website
Commits
9a7baf27
Commit
9a7baf27
authored
Dec 16, 2017
by
Julian Rother
Browse files
Fixed job_handler
parent
0818d5cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
server.py
View file @
9a7baf27
...
...
@@ -480,7 +480,6 @@ def dbstatus():
clusters
[
cluster
].
append
(
host
)
return
render_template
(
'dbstatus.html'
,
clusters
=
clusters
,
statuses
=
status
,
vars
=
variables
),
200
job_handlers
=
{}
def
job_handler
(
*
types
,
state
=
'finished'
):
def
wrapper
(
func
):
...
...
@@ -490,10 +489,9 @@ def job_handler(*types, state='finished'):
if
state
not
in
job_handlers
[
jobtype
]:
job_handlers
[
jobtype
][
state
]
=
[]
job_handlers
[
jobtype
][
state
].
append
(
func
)
return
func
return
func
return
wrapper
def
date_json_handler
(
obj
):
return
obj
.
isoformat
()
if
hasattr
(
obj
,
'isoformat'
)
else
obj
...
...
Write
Preview
Supports
Markdown
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