Skip to content

Commit 06a084c

Browse files
authored
Merge pull request #278 from python-adaptive/skopt-importerror
prevent ImportError due to scikit-optimize and sklearn incompatibility
2 parents 1c60897 + c70b3ac commit 06a084c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

adaptive/tests/test_learners.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@
2929

3030
try:
3131
from adaptive.learner.skopt_learner import SKOptLearner
32-
except ModuleNotFoundError:
32+
except (ModuleNotFoundError, ImportError):
33+
# XXX: catch the ImportError because of https://github.com/scikit-optimize/scikit-optimize/issues/902
3334
SKOptLearner = None
3435

3536

0 commit comments

Comments
 (0)