Skip to content

Commit 9dc7cc5

Browse files
committed
catch correct error
1 parent c101adc commit 9dc7cc5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

taskvine/src/bindings/python3/ndcctools/taskvine/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ class DaskVineWarning(UserWarning):
7575

7676
from .dask_executor import DaskVine
7777
from .dask_dag import DaskVineDag
78-
except ImportError:
78+
except (ImportError, ModuleNotFoundError):
7979
warnings.warn("Dask >= 2024.12.0 not available, using DaskVine legacy task graph representation.", DaskVineWarning)
8080

8181
from .compat import DaskVine

taskvine/src/bindings/python3/ndcctools/taskvine/compat/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535

3636
if vd >= vr:
3737
warnings.warn("ndcctools.taskvine.compat only works with dask version < 2024.12.0")
38-
except ImportError:
38+
except (ImportError, ModuleNotFoundError):
3939
pass
4040

4141

0 commit comments

Comments
 (0)