Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Scientific Software
MDANSE
Commits
d206af09
Commit
d206af09
authored
Jul 26, 2018
by
eric pellegrini
Browse files
Added better error handling when a job fail from the GUI
parent
5cffc462
Pipeline
#4249
passed with stages
in 8 minutes and 51 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
MDANSE/GUI/Plugins/JobPlugin.py
View file @
d206af09
...
...
@@ -41,7 +41,6 @@ import wx.aui as aui
from
MDANSE
import
PLATFORM
,
REGISTRY
from
MDANSE.Framework.InputData.EmptyData
import
EmptyData
from
MDANSE.Framework.Jobs.IJob
import
JobError
from
MDANSE.GUI
import
PUBLISHER
from
MDANSE.GUI.DataController
import
DATA_CONTROLLER
...
...
@@ -123,10 +122,12 @@ class JobPlugin(ComponentPlugin):
try
:
subprocess
.
check_output
([
sys
.
executable
,
filename
],
stderr
=
subprocess
.
STDOUT
)
except
subprocess
.
CalledProcessError
as
e
:
raise
JobError
(
e
.
output
)
message
=
e
.
output
else
:
time
.
sleep
(
1
)
PUBLISHER
.
sendMessage
(
"msg_start_job"
,
message
=
None
)
message
=
None
time
.
sleep
(
1
)
PUBLISHER
.
sendMessage
(
"msg_start_job"
,
message
=
message
)
def
on_save
(
self
,
event
=
None
):
...
...
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