Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
genotoul-bioinfo
jflow
Commits
3afa3927
Commit
3afa3927
authored
Sep 23, 2015
by
Jerome Mariette
Browse files
from python2 to python3 > ok from command line
parent
61fa1721
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/jflow/server.py
View file @
3afa3927
...
@@ -161,9 +161,10 @@ class JFlowServer (object):
...
@@ -161,9 +161,10 @@ class JFlowServer (object):
value
=
func
(
*
args
,
**
kw
)
value
=
func
(
*
args
,
**
kw
)
cherrypy
.
response
.
headers
[
"Content-Type"
]
=
"application/json"
cherrypy
.
response
.
headers
[
"Content-Type"
]
=
"application/json"
# if JSONP request
# if JSONP request
if
"callback"
in
kw
:
return
kw
[
"callback"
]
+
"("
+
json
.
dumps
(
value
,
cls
=
JFlowJSONEncoder
)
+
")"
if
"callback"
in
kw
:
return
(
'%s(%s)'
%
(
kw
[
"callback"
],
json
.
dumps
(
value
,
cls
=
JFlowJSONEncoder
))).
encode
(
'utf8'
)
# else return the JSON
# else return the JSON
else
:
return
json
.
dumps
(
value
)
else
:
return
json
.
dumps
(
value
,
cls
=
JFlowJSONEncoder
).
encode
(
'utf8'
)
return
wrapper
return
wrapper
def
jsonify_workflow_status
(
self
,
workflow
,
init_to_zero
=
False
):
def
jsonify_workflow_status
(
self
,
workflow
,
init_to_zero
=
False
):
...
...
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