From c798908c58410499c513efc023d397d184f76f09 Mon Sep 17 00:00:00 2001 From: Quentin Date: Wed, 26 Feb 2025 18:32:19 +0100 Subject: [PATCH 1/6] update version --- src/radius_clustering/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/radius_clustering/__init__.py b/src/radius_clustering/__init__.py index 5a8d7af..781aaed 100644 --- a/src/radius_clustering/__init__.py +++ b/src/radius_clustering/__init__.py @@ -4,4 +4,4 @@ __all__ = ["RadiusClustering"] # Optionally, you can set a version number for your package -__version__ = "1.2.0" +__version__ = "1.2.1" From 8631db0b03373f19e3f2ef2e39e5a11be5c48386 Mon Sep 17 00:00:00 2001 From: Quentin Date: Wed, 26 Feb 2025 18:35:08 +0100 Subject: [PATCH 2/6] fix pyproject typo --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 098901c..ec6b36d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -80,7 +80,7 @@ doc = [ [tool.setuptools] packages.find = {where = ["src"], include = ["radius_clustering", "radius_clustering.*"]} -version = {attr = "radius_clustering.__version__"} +dynamic.version = {attr = "radius_clustering.__version__"} [tool.pytest.ini_options] pythonpath = "src" From 1b953fe7870ff0704deee105edc4f844d092a425 Mon Sep 17 00:00:00 2001 From: Quentin Date: Wed, 26 Feb 2025 18:39:28 +0100 Subject: [PATCH 3/6] fix dependency for tests --- .github/workflows/tests.yml | 2 +- pyproject.toml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d18d816..2ebeb97 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -20,7 +20,7 @@ jobs: run: | python -m pip install --upgrade pip python -m pip install pytest - python -m pip install -e . + python -m pip install -e ".[dev]" - name: Run tests with pytest run: | diff --git a/pyproject.toml b/pyproject.toml index ec6b36d..6218a72 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,6 +51,7 @@ documentation = "https://lias-laboratory.github.io/radius_clustering/" [project.optional-dependencies] dev = [ "pytest>=8.3.3", + "pandas", "cython>=3.0", "setuptools>= 61.0", "black>=24.3.0", From 13351f9c7f233faf59fc806d40a717a4552762f6 Mon Sep 17 00:00:00 2001 From: Quentin Date: Wed, 26 Feb 2025 18:42:15 +0100 Subject: [PATCH 4/6] fix buffer error --- src/radius_clustering/utils/mds.pyx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/radius_clustering/utils/mds.pyx b/src/radius_clustering/utils/mds.pyx index 1112db2..488ae90 100644 --- a/src/radius_clustering/utils/mds.pyx +++ b/src/radius_clustering/utils/mds.pyx @@ -39,7 +39,7 @@ cdef extern from "mds_core.cpp": cdef Result iterated_greedy_wrapper(int numNodes, const vector[int]& edges_list, int nb_edges, string name) nogil -def solve_mds(int num_nodes, np.ndarray[np.uint32_t, ndim=1, mode="c"] edges not None, int nb_edges, str name): +def solve_mds(int num_nodes, np.ndarray[int, ndim=1, mode="c"] edges not None, int nb_edges, str name): """ Solve the Minimum Dominating Set problem for a given graph. From 87e214c1eb5ef5b2447f5ad61a3919da05a44f33 Mon Sep 17 00:00:00 2001 From: Quentin Date: Thu, 27 Feb 2025 10:09:05 +0100 Subject: [PATCH 5/6] fix bug in test workflow --- .github/workflows/pr_build.yml | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pr_build.yml b/.github/workflows/pr_build.yml index c6ad8a3..b54a30d 100644 --- a/.github/workflows/pr_build.yml +++ b/.github/workflows/pr_build.yml @@ -10,10 +10,14 @@ jobs: run_pytest: name: Run pytest uses: ./.github/workflows/tests.yml - + build_test_wheels: name: Test build on Ubuntu runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + python-version: [3.9, 3.10, 3.11, 3.12, 3.13] steps: - uses: actions/checkout@v4 @@ -23,10 +27,19 @@ jobs: package-dir: . output-dir: ./wheelhouse config-file: "{package}/pyproject.toml" + + - name: Setup Python + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python-version }} - name: Test import run: | - pip install ./wheelhouse/*.whl + PY_VESION=$(echo ${{ matrix.python-version }} | sed 's/\.//g') + + ls -la ./wheelhouse/ + + pip install ./wheelhouse/*cp${PY_VERSION}*.whl python -c "import radius_clustering; print(f'Successfully imported version {radius_clustering.__version__}')" build_test_sdist: From c0e9aa304bdf19fed01df2edd815ec96c140b04a Mon Sep 17 00:00:00 2001 From: Quentin Date: Thu, 27 Feb 2025 10:20:17 +0100 Subject: [PATCH 6/6] fixing typo and version for yaml parsing correctly --- .github/workflows/pr_build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pr_build.yml b/.github/workflows/pr_build.yml index b54a30d..8adecff 100644 --- a/.github/workflows/pr_build.yml +++ b/.github/workflows/pr_build.yml @@ -17,7 +17,7 @@ jobs: strategy: fail-fast: false matrix: - python-version: [3.9, 3.10, 3.11, 3.12, 3.13] + python-version: ['3.9', '3.10', '3.11', '3.12', '3.13'] steps: - uses: actions/checkout@v4 @@ -35,7 +35,7 @@ jobs: - name: Test import run: | - PY_VESION=$(echo ${{ matrix.python-version }} | sed 's/\.//g') + PY_VERSION=$(echo ${{ matrix.python-version }} | sed 's/\.//g') ls -la ./wheelhouse/