From 07ae53a7dbd9d786e400cf194eee8539aa7e39f0 Mon Sep 17 00:00:00 2001 From: Mattijn van Hoek Date: Wed, 1 Nov 2023 19:51:53 +0100 Subject: [PATCH] raise RunTimeError when package version is too low --- altair/utils/_importers.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/altair/utils/_importers.py b/altair/utils/_importers.py index d8bf20047..388d379f5 100644 --- a/altair/utils/_importers.py +++ b/altair/utils/_importers.py @@ -8,7 +8,7 @@ def import_vegafusion() -> ModuleType: try: version = importlib_version("vegafusion") if Version(version) < Version(min_version): - raise ImportError( + raise RuntimeError( f"The vegafusion package must be version {min_version} or greater. " f"Found version {version}" ) @@ -33,7 +33,7 @@ def import_vl_convert() -> ModuleType: try: version = importlib_version("vl-convert-python") if Version(version) < Version(min_version): - raise ImportError( + raise RuntimeError( f"The vl-convert-python package must be version {min_version} or greater. " f"Found version {version}" ) @@ -58,7 +58,7 @@ def import_pyarrow_interchange() -> ModuleType: version = importlib_version("pyarrow") if Version(version) < Version(min_version): - raise ImportError( + raise RuntimeError( f"The pyarrow package must be version {min_version} or greater. " f"Found version {version}" )