Skip to content

Commit 33d5a30

Browse files
committed
BUG: Fix detection of itk package
It is possible that the `itk` metapackage is not install, but one of the more specific packages were just installed, e.g. `itk-filtering`. Check for `itk-core`, which will always be installed and which has the required functionality, when checking for ITK Python.
1 parent f4f1c4f commit 33d5a30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

itkwidgets/integrations/itk.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import importlib_metadata
55
HAVE_ITK = False
66
try:
7-
itk_version = importlib_metadata.version('itk')
7+
itk_version = importlib_metadata.version('itk-core')
88
if version.parse(itk_version) < version.parse('5.3.0'):
99
raise RuntimeError('itk 5.3 or newer is required. `pip install itk>=5.3.0`')
1010
HAVE_ITK = True

0 commit comments

Comments
 (0)