Skip to content

Commit 077df38

Browse files
Merge pull request #3466 from antgonza/raise-error-resource-alloc
propagate error from resource_allocation_info
2 parents d0e03de + 734d414 commit 077df38

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

qiita_db/processing_job.py

+7-1
Original file line numberDiff line numberDiff line change
@@ -1049,7 +1049,13 @@ def submit(self, parent_job_id=None, dependent_jobs_list=None):
10491049
# before returning immediately, usually with a job ID that can
10501050
# be used to monitor the job's progress.
10511051

1052-
resource_params = self.resource_allocation_info
1052+
try:
1053+
resource_params = self.resource_allocation_info
1054+
except qdb.exceptions.QiitaDBUnknownIDError as e:
1055+
# this propagates the error to the job and using str(e)
1056+
# should be fine as we just want the last calculation
1057+
# error
1058+
self._set_error(str(e))
10531059

10541060
# note that parent_job_id is being passed transparently from
10551061
# submit declaration to the launcher.

0 commit comments

Comments
 (0)