Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove distutils for python>3.11 compatibility #263

Merged
merged 2 commits into from
Jan 3, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions birdy/client/converters.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

import tempfile
from collections.abc import Sequence
from distutils.version import StrictVersion
from importlib import import_module
from pathlib import Path
from typing import Union

from owslib.wps import Output
from packaging.version import Version

from birdy.utils import is_opendap_url

Expand Down Expand Up @@ -170,8 +170,8 @@ def check_dependencies(self): # noqa: D102
self._check_import("netCDF4")
from netCDF4 import getlibversion

version = StrictVersion(getlibversion().split(" ")[0])
if version < StrictVersion("4.5"):
version = Version(getlibversion().split(" ")[0])
if version < Version("4.5"):
raise ImportError("netCDF4 library must be at least version 4.5")

def convert(self): # noqa: D102
Expand Down
Loading