Skip to content

Commit 4202b36

Browse files
authored
Flux: Handle finished future objects (#835)
* Flux: Handle finished future objects * Add files via upload
1 parent 276ef56 commit 4202b36

File tree

2 files changed

+4
-540
lines changed

2 files changed

+4
-540
lines changed

executorlib/task_scheduler/interactive/spawner_flux.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import contextlib
12
import os
23
from typing import Callable, Optional
34

@@ -147,7 +148,8 @@ def shutdown(self, wait: bool = True):
147148
# The flux future objects are not instantly updated,
148149
# still showing running after cancel was called,
149150
# so we wait until the execution is completed.
150-
self._future.result()
151+
with contextlib.suppress(flux.job.event.JobException):
152+
self._future.result()
151153

152154
def poll(self):
153155
"""

0 commit comments

Comments
 (0)