diff --git a/calmap/__init__.py b/calmap/__init__.py index 7651522..2ddb034 100644 --- a/calmap/__init__.py +++ b/calmap/__init__.py @@ -15,7 +15,7 @@ import matplotlib.pyplot as plt import numpy as np import pandas as pd -from distutils.version import StrictVersion +from packaging import version from dateutil.relativedelta import relativedelta from matplotlib.patches import Polygon @@ -28,7 +28,7 @@ __contact__ = "marvin.thielk@gmail.com, martijn@vermaat.name" __homepage__ = "https://github.com/MarvinT/calmap" -_pandas_18 = StrictVersion(pd.__version__) >= StrictVersion("0.18") +_pandas_18 = version.parse(pd.__version__) >= version.parse("0.18") def yearplot( diff --git a/setup.py b/setup.py index 6f52f4e..ffff4bb 100644 --- a/setup.py +++ b/setup.py @@ -1,7 +1,7 @@ import os from setuptools import setup -install_requires = ["matplotlib", "numpy", "pandas"] +install_requires = ["matplotlib", "packaging", "numpy", "pandas"] try: with open("README.md") as readme: