diff --git a/pandas_alive/geocharts.py b/pandas_alive/geocharts.py index c26055d..2dce2d8 100644 --- a/pandas_alive/geocharts.py +++ b/pandas_alive/geocharts.py @@ -6,6 +6,7 @@ from typing import Mapping import attr +import geopandas import matplotlib.dates as mdates import matplotlib.pyplot as plt import matplotlib.units as munits @@ -184,9 +185,8 @@ def plot_geo_data(self, i: int, gdf: geopandas.GeoDataFrame) -> None: contextily.add_basemap(self.ax) except ImportError: - import warnings - warnings.warn( + raise ModuleNotFoundError( "Ensure contextily is installed for basemap functionality https://github.com/geopandas/contextily" )