Skip to content

Commit

Permalink
Add packaging as an install dependency (#320)
Browse files Browse the repository at this point in the history
  • Loading branch information
brendan-ward authored Oct 28, 2023
1 parent 97d9dee commit fde8b28
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
6 changes: 6 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# CHANGELOG

## 0.7.2 (2023-10-27)

### Bug fixes

- Add `packaging` as a dependency (#320).

## 0.7.1 (2023-10-26)

### Bug fixes
Expand Down
4 changes: 3 additions & 1 deletion pyogrio/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
import sys
from urllib.parse import urlparse

from packaging.version import Version

from pyogrio._env import GDALEnv

with GDALEnv():
Expand Down Expand Up @@ -187,7 +189,7 @@ def _mask_to_wkb(mask):
try:
import shapely

if int(shapely.__version__.split(".")[0]) < 2:
if Version(shapely.__version__) < Version("2.0.0"):
shapely = None
except ImportError:
shapely = None
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ def run(self):
long_description_content_type="text/markdown",
long_description=open("README.md").read(),
python_requires=">=3.8",
install_requires=["certifi", "numpy"],
install_requires=["certifi", "numpy", "packaging"],
extras_require={
"dev": ["Cython"],
"test": ["pytest", "pytest-cov"],
Expand Down

0 comments on commit fde8b28

Please sign in to comment.