diff --git a/biology/py-loompy/Makefile b/biology/py-loompy/Makefile index 86b5253964a4..591cf8157082 100644 --- a/biology/py-loompy/Makefile +++ b/biology/py-loompy/Makefile @@ -1,28 +1,32 @@ PORTNAME= loompy -DISTVERSION= 3.0.7 -PORTREVISION= 4 +DISTVERSION= 3.0.8 CATEGORIES= biology python MASTER_SITES= PYPI PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} MAINTAINER= yuri@FreeBSD.org COMMENT= Work with .loom files for single-cell RNA-seq data WWW= https://loompy.org/ LICENSE= BSD2CLAUSE LICENSE_FILE= ${WRKSRC}/LICENSE -RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}numpy>=1.16:math/py-numpy@${PY_FLAVOR} \ - ${PYTHON_PKGNAMEPREFIX}click>0:devel/py-click@${PY_FLAVOR} \ +BUILD_DEPENDS= ${PY_SETUPTOOLS} \ + ${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR} +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}click>0:devel/py-click@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}h5py>0:science/py-h5py@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}numba>0:devel/py-numba@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}numpy>=1.16:math/py-numpy@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}numpy-groupies>0:math/py-numpy-groupies@${PY_FLAVOR} \ - ${PYTHON_PKGNAMEPREFIX}pandas>0:math/py-pandas@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}scipy>0:science/py-scipy@${PY_FLAVOR} USES= python -USE_PYTHON= distutils autoplist +USE_PYTHON= pep517 autoplist pytest NO_ARCH= yes +TEST_ENV= ${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR} + +# tests as of 3.0.8: 8 passed, 1 failed + .include diff --git a/biology/py-loompy/distinfo b/biology/py-loompy/distinfo index 633ef090896f..fbdb1a54a64d 100644 --- a/biology/py-loompy/distinfo +++ b/biology/py-loompy/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1646583060 -SHA256 (loompy-3.0.7.tar.gz) = b5cdf7b54734c6bed3a181d11947af70af2c6e0dcadc02fd0e871df232faa8f4 -SIZE (loompy-3.0.7.tar.gz) = 4837617 +TIMESTAMP = 1780912743 +SHA256 (loompy-3.0.8.tar.gz) = c1f48d0bf21aa2bbdeee21a0577553cba9609d9435d7c32b687686bbb5869ca7 +SIZE (loompy-3.0.8.tar.gz) = 49618 diff --git a/biology/py-loompy/files/patch-tests_test__connection.py b/biology/py-loompy/files/patch-tests_test__connection.py new file mode 100644 index 000000000000..193c3209614e --- /dev/null +++ b/biology/py-loompy/files/patch-tests_test__connection.py @@ -0,0 +1,26 @@ +-- Fix tests for FreeBSD (don't delete temporary files on close, fix np.int). + +-- Fix np.int usage for NumPy 2.0+ compatibility. + +--- tests/test_connection.py.orig 2021-10-05 14:19:26 UTC ++++ tests/test_connection.py +@@ -8,16 +8,16 @@ class LoomConnectionTests(TestCase): + + class LoomConnectionTests(TestCase): + def setUp(self) -> None: +- self.file = NamedTemporaryFile(suffix=".loom") ++ self.file = NamedTemporaryFile(suffix=".loom", delete=False) + self.file.close() + loompy.create( + self.file.name, + np.random.random((5, 5)), + row_attrs={ +- "key": np.fromiter(range(5), dtype=np.int) ++ "key": np.fromiter(range(5), dtype=int) + }, + col_attrs={ +- "key": np.fromiter(range(5), dtype=np.int) ++ "key": np.fromiter(range(5), dtype=int) + }) + + def tearDown(self) -> None: diff --git a/biology/py-loompy/files/patch-tests_test__file__attribute__manager.py b/biology/py-loompy/files/patch-tests_test__file__attribute__manager.py new file mode 100644 index 000000000000..dd50f169fc48 --- /dev/null +++ b/biology/py-loompy/files/patch-tests_test__file__attribute__manager.py @@ -0,0 +1,13 @@ +-- Fix tests for FreeBSD (don't delete temporary files on close, fix np.int). + +--- tests/test_file_attribute_manager.py.orig 2026-06-08 10:21:32 UTC ++++ tests/test_file_attribute_manager.py +@@ -12,7 +12,7 @@ class GlobalAttributeManagerTests(TestCase): + VALUE_IN_FILE = np.arange(3) + + def setUp(self): +- f = NamedTemporaryFile(suffix="loom") ++ f = NamedTemporaryFile(suffix="loom", delete=False) + f.close() + self.filename = f.name + self.file = h5py.File(f.name) diff --git a/biology/py-loompy/files/patch-tests_test__validator.py b/biology/py-loompy/files/patch-tests_test__validator.py new file mode 100644 index 000000000000..4fb215e41ba7 --- /dev/null +++ b/biology/py-loompy/files/patch-tests_test__validator.py @@ -0,0 +1,13 @@ +-- Fix tests for FreeBSD (don't delete temporary files on close, fix np.int). + +--- tests/test_validator.py.orig 2026-06-08 10:21:32 UTC ++++ tests/test_validator.py +@@ -9,7 +9,7 @@ class LoomValidatorTests(TestCase): + + class LoomValidatorTests(TestCase): + def test_file_with_empty_col_attrs_is_valid(self) -> None: +- f = NamedTemporaryFile(suffix=".loom") ++ f = NamedTemporaryFile(suffix=".loom", delete=False) + f.close() + loompy.create(f.name, np.zeros((5, 5)), {}, {}) + try: