From 7a922b049fccaa03abb011ef64abda6ac53f61ea Mon Sep 17 00:00:00 2001 From: John Kerl Date: Tue, 21 Nov 2023 16:23:27 -0500 Subject: [PATCH] Update pyarrow dependency (#182) --- pyproject.toml | 5 ++++- python-spec/requirements-py3.10.txt | 1 + python-spec/requirements-py3.7.txt | 1 + python-spec/requirements-py3.8-lint.txt | 1 + python-spec/requirements-py3.8.txt | 1 + python-spec/requirements-py3.9.txt | 1 + python-spec/src/somacore/__init__.py | 5 +++++ 7 files changed, 14 insertions(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d4a6fd21..843a2aaa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -17,6 +17,9 @@ dependencies = [ "numpy>=1.21", "pandas", "pyarrow", + # TODO: once we no longer support Python 3.7, remove this and pin to pyarrow >= 14.0.1 + # https://github.com/single-cell-data/TileDB-SOMA/issues/1926 + "pyarrow-hotfix", "scipy", "typing-extensions>=4.1", # For LiteralString ] @@ -56,5 +59,5 @@ warn_redundant_casts = true [[tool.mypy.overrides]] # These dependencies do not currently have canonical type stubs. -module = ["anndata", "numba", "pandas", "pyarrow", "scipy"] +module = ["anndata", "numba", "pandas", "pyarrow", "pyarrow_hotfix", "scipy"] ignore_missing_imports = true diff --git a/python-spec/requirements-py3.10.txt b/python-spec/requirements-py3.10.txt index 634cc44f..8958867a 100644 --- a/python-spec/requirements-py3.10.txt +++ b/python-spec/requirements-py3.10.txt @@ -8,6 +8,7 @@ numpy==1.25.2 packaging==23.1 pandas==2.1.1 pyarrow==13.0.0 +pyarrow_hotfix==0.6.0 python-dateutil==2.8.2 pytz==2023.3.post1 scipy==1.11.3 diff --git a/python-spec/requirements-py3.7.txt b/python-spec/requirements-py3.7.txt index b7d5617d..cd13e212 100644 --- a/python-spec/requirements-py3.7.txt +++ b/python-spec/requirements-py3.7.txt @@ -9,6 +9,7 @@ numpy==1.21.6 packaging==23.1 pandas==1.3.5 pyarrow==12.0.1 +pyarrow_hotfix==0.6.0 python-dateutil==2.8.2 pytz==2023.3.post1 scipy==1.7.3 diff --git a/python-spec/requirements-py3.8-lint.txt b/python-spec/requirements-py3.8-lint.txt index b5d21a14..d20d9883 100644 --- a/python-spec/requirements-py3.8-lint.txt +++ b/python-spec/requirements-py3.8-lint.txt @@ -22,6 +22,7 @@ pathspec==0.11.2 platformdirs==3.10.0 pre-commit==3.4.0 pyarrow==13.0.0 +pyarrow_hotfix==0.6.0 python-dateutil==2.8.2 pytz==2023.3.post1 PyYAML==6.0.1 diff --git a/python-spec/requirements-py3.8.txt b/python-spec/requirements-py3.8.txt index a652c0de..e44bafe3 100644 --- a/python-spec/requirements-py3.8.txt +++ b/python-spec/requirements-py3.8.txt @@ -9,6 +9,7 @@ numpy==1.24.4 packaging==23.1 pandas==2.0.3 pyarrow==13.0.0 +pyarrow_hotfix==0.6.0 python-dateutil==2.8.2 pytz==2023.3.post1 scipy==1.10.1 diff --git a/python-spec/requirements-py3.9.txt b/python-spec/requirements-py3.9.txt index 194ec037..e2e95445 100644 --- a/python-spec/requirements-py3.9.txt +++ b/python-spec/requirements-py3.9.txt @@ -10,6 +10,7 @@ numpy==1.25.2 packaging==23.1 pandas==2.1.1 pyarrow==13.0.0 +pyarrow_hotfix==0.6.0 python-dateutil==2.8.2 pytz==2023.3.post1 rsa==4.7.2 diff --git a/python-spec/src/somacore/__init__.py b/python-spec/src/somacore/__init__.py index 21b0c941..2cce016d 100644 --- a/python-spec/src/somacore/__init__.py +++ b/python-spec/src/somacore/__init__.py @@ -9,6 +9,11 @@ from typing import Tuple, Union +# TODO: once we no longer support Python 3.7, remove this and pin to pyarrow >= 14.0.1 +# https://github.com/single-cell-data/TileDB-SOMA/issues/1926 +# ruff: noqa +import pyarrow_hotfix + from .base import SOMAObject from .collection import Collection from .data import DataFrame