From 713c029e0cdfc7d8cadda588c6a1078efb94e8e5 Mon Sep 17 00:00:00 2001 From: Josh Levy-Kramer Date: Thu, 3 Oct 2024 14:22:53 +0100 Subject: [PATCH] Tidy --- .github/workflows/build_wheels.yml | 7 ++++--- README.md | 4 ++-- README_dev.md | 23 +++++------------------ 3 files changed, 11 insertions(+), 23 deletions(-) diff --git a/.github/workflows/build_wheels.yml b/.github/workflows/build_wheels.yml index a9e5506..48435f6 100644 --- a/.github/workflows/build_wheels.yml +++ b/.github/workflows/build_wheels.yml @@ -19,6 +19,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: + # Check for latest setpup: https://github.com/pypa/cibuildwheel/blob/main/examples/github-with-qemu.yml os: [ubuntu-latest, windows-latest, macos-13, macos-14] python: [cp310, cp311, cp312] # As of 3/Oct/24 ortools was not compatible with cp313 include: @@ -41,10 +42,10 @@ jobs: steps: - name: Set up QEMU if: matrix.arch == 'aarch64' - uses: docker/setup-qemu-action@v2 + uses: docker/setup-qemu-action@v3 with: platforms: arm64 - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Build and test wheels uses: pypa/cibuildwheel@v2.21.2 # You may need to update to get latest Python versions env: @@ -58,6 +59,6 @@ jobs: # Test CIBW_BEFORE_TEST: "pip install --upgrade pip && pip install -r requirements-dev.txt && pip list" CIBW_TEST_COMMAND: "pytest {project}/tests" - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl \ No newline at end of file diff --git a/README.md b/README.md index e0ada6c..756efe4 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ [![PyPI](https://img.shields.io/pypi/v/k-means-constrained)](https://pypi.org/project/k-means-constrained/) -![Python](https://img.shields.io/badge/python-3.10%20%7C%203.11%20%7C%203.12%20%7C%203.13-blue) +![Python](https://img.shields.io/badge/python-3.10%20%7C%203.11%20%7C%203.12-blue) [![Build](https://github.com/joshlk/k-means-constrained/actions/workflows/build_wheels.yml/badge.svg)](https://github.com/joshlk/k-means-constrained/actions/workflows/build_wheels.yml) [**Documentation**](https://joshlk.github.io/k-means-constrained/) @@ -120,7 +120,7 @@ Below is a runtime comparison between k-means and k-means-constrained whereby th # Change log -* v0.7.4 compatible with Numpy +v2.1.1. Added Python 3.12 and 3.13 support. Dropped Python 3.8 and 3.9 support (in line with Numpy). +* v0.7.4 compatible with Numpy +v2.1.1. Added Python 3.12 support and dropped Python 3.8 and 3.9 support (due to Numpy). * v0.7.3 compatible with Numpy v1.23.0 to 1.26.4 # Citations diff --git a/README_dev.md b/README_dev.md index 61d6bce..195e49b 100644 --- a/README_dev.md +++ b/README_dev.md @@ -24,7 +24,6 @@ pytest ``` 2. Push changes to GitHub to build it for all platforms (if you get errors check notes above) - MacOS isn't tested so download a copy and test locally. 3. Add changes to change log and bump version (major, minor or patch): @@ -32,44 +31,32 @@ pytest bump2version patch ``` - - -Push to GitHub to build for many version. The MacOS ARM build isn't automatically tested and so should be tested locally. - -# Push to PyPi -Requires: `pip install twine` -Don't forget to increment version number - -Bump version (major, minor or patch): - - - -Download distributions (artifacts) +4. Download distributions (artifacts) ```shell script make download-dists ID=$BUILD_ID ``` -Upload to test PyPi +5. Upload to test PyPi ```shell script make check-dist make test-pypi ``` -Activate virtual env (might need to `make venv-create`) +6. Activate virtual env (might need to `make venv-create`) ```shell script source k-means-env/bin/activate ``` -Test install (in virtual env. *****Remember to cd out of k-means-constrained folder*****): +7. Test install (in virtual env. *****Remember to cd out of k-means-constrained folder*****): ```shell script pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple k-means-constrained ``` -Then push to real PyPI: +8. Then push to real PyPI: ```shell script make pypi-upload