mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Raise JobMappingException when tool has been removed
That fixes the underlying problem in https://github.com/galaxyproject/galaxy/issues/8141 but doesn't implement the outer try/except suggested by @natefoo.
This commit is contained in:
@@ -1173,6 +1173,9 @@ class JobWrapper(HasResourceParameters):
|
||||
"destination for completion of fail method", self.get_id_tag(), str(exc.failure_message))
|
||||
self.job_runner_mapper.cached_job_destination = JobDestination(id='__fail__')
|
||||
|
||||
# Might be AssertionError or other exception
|
||||
message = str(message)
|
||||
|
||||
# if the job was deleted, don't fail it
|
||||
if not job.state == job.states.DELETED:
|
||||
# Check if the failure is due to an exception
|
||||
|
||||
@@ -207,6 +207,10 @@ class JobRunnerMapper(object):
|
||||
return job_destination
|
||||
|
||||
def __determine_job_destination(self, params, raw_job_destination=None):
|
||||
if self.job_wrapper.tool is None:
|
||||
raise JobMappingException(
|
||||
"Can't map job to destination, tool '%s' is unavailable" % self.job_wrapper.get_job().tool_id
|
||||
)
|
||||
if raw_job_destination is None:
|
||||
raw_job_destination = self.job_wrapper.tool.get_job_destination(params)
|
||||
if raw_job_destination.runner == DYNAMIC_RUNNER_NAME:
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import time
|
||||
|
||||
from base import integration_util
|
||||
from base.populators import (
|
||||
DatasetPopulator,
|
||||
|
||||
Reference in New Issue
Block a user