Skip to content

Commit

Permalink
more chaining
Browse files Browse the repository at this point in the history
  • Loading branch information
tphung3 committed Oct 25, 2023
1 parent 54c846c commit 092b3d2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions parsl/executors/workqueue/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -738,7 +738,9 @@ def _collect_work_queue_results(self):
result = deserialize(f_in.read())
except Exception as e:
logger.error(f'Cannot load result from result file {task_report.result_file}. Exception: {e}')
future.set_exception(WorkQueueTaskFailure('Cannot load result from result file', None))
ex = WorkQueueTaskFailure('Cannot load result from result file', None)
ex.__cause__ = e
future.set_exception(ex)
else:
if isinstance(result, Exception):
ex = WorkQueueTaskFailure('Task execution raises an exception', result)
Expand All @@ -749,7 +751,7 @@ def _collect_work_queue_results(self):
else:
# If there are no results, then the task failed according to one of
# work queue modes, such as resource exhaustion.
ex = WorkQueueTaskFailure(task_report.reason, Exception(task_report.reason))
ex = WorkQueueTaskFailure(task_report.reason, None)
future.set_exception(ex)
finally:
logger.debug("Marking all outstanding tasks as failed")
Expand Down

0 comments on commit 092b3d2

Please sign in to comment.