From d22296f577ac4cfc1a3c072315d885e5bfdccf98 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sun, 21 Jan 2024 15:31:01 -0500 Subject: [PATCH 01/22] Start compiling code with ABI --- Cargo.toml | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index af785845ff..64806fb618 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -61,7 +61,7 @@ rustworkx-core = { path = "rustworkx-core", version = "=0.14.0" } [dependencies.pyo3] version = "0.20.2" -features = ["extension-module", "hashbrown", "num-bigint", "num-complex", "indexmap"] +features = ["abi3-py38","extension-module", "hashbrown", "num-bigint", "num-complex", "indexmap"] [dependencies.ndarray] version = "^0.15.6" diff --git a/setup.py b/setup.py index cb8f99872e..0e64839fca 100644 --- a/setup.py +++ b/setup.py @@ -30,7 +30,7 @@ def readme(): PKG_PACKAGES = ["rustworkx", "rustworkx.visualization"] PKG_INSTALL_REQUIRES = ["numpy>=1.16.0,<2"] RUST_EXTENSIONS = [RustExtension("rustworkx.rustworkx", "Cargo.toml", - binding=Binding.PyO3, debug=rustworkx_debug)] + binding=Binding.PyO3, debug=rustworkx_debug, py_limited_api=True)] retworkx_readme_compat = """# retworkx From 43908ab46de68ce7347f58cc56e9d719971fbde5 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sun, 21 Jan 2024 17:11:18 -0500 Subject: [PATCH 02/22] Copy code from Qiskit --- setup.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 0e64839fca..9da2e83905 100644 --- a/setup.py +++ b/setup.py @@ -30,7 +30,8 @@ def readme(): PKG_PACKAGES = ["rustworkx", "rustworkx.visualization"] PKG_INSTALL_REQUIRES = ["numpy>=1.16.0,<2"] RUST_EXTENSIONS = [RustExtension("rustworkx.rustworkx", "Cargo.toml", - binding=Binding.PyO3, debug=rustworkx_debug, py_limited_api=True)] + binding=Binding.PyO3, debug=rustworkx_debug)] +RUST_OPTS ={"bdist_wheel": {"py_limited_api": "cp38"}} retworkx_readme_compat = """# retworkx @@ -91,5 +92,6 @@ def readme(): "mpl": mpl_extras, "graphviz": graphviz_extras, "all": mpl_extras + graphviz_extras, - } + }, + options=RUST_OPTS, ) From 593c5225043927403dd7632d7a28cbf6f4e57c47 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sun, 21 Jan 2024 18:35:34 -0500 Subject: [PATCH 03/22] Remove duplicates --- .github/workflows/wheels.yml | 157 +---------------------------------- 1 file changed, 4 insertions(+), 153 deletions(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index 29e175372b..2232205326 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -109,44 +109,7 @@ jobs: python -m cibuildwheel --output-dir wheelhouse env: CIBW_ARCHS_LINUX: aarch64 - CIBW_SKIP: cp36-* cp37-* cp311-* cp312-* pp* *musl* - - uses: actions/upload-artifact@v3 - with: - path: ./wheelhouse/*.whl - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: wheelhouse/ - build_wheels_aarch64_part_2: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - permissions: - id-token: write - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 - name: Install Python - with: - python-version: '3.8' - - uses: dtolnay/rust-toolchain@stable - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: all - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.16.2 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_ARCHS_LINUX: aarch64 - CIBW_SKIP: cp36-* cp37-* cp38-* cp39-* cp310-* pp* *musl* + CIBW_SKIP: cp36-* cp37-* pp* *musl* - uses: actions/upload-artifact@v3 with: path: ./wheelhouse/*.whl @@ -183,45 +146,7 @@ jobs: python -m cibuildwheel --output-dir wheelhouse env: CIBW_ARCHS_LINUX: aarch64 - CIBW_SKIP: cp36-* cp37-* cp311-* cp312-* *many* - CIBW_TEST_SKIP: cp37-* cp38-* cp39-* cp310-* cp311-* cp312-* *many* - - uses: actions/upload-artifact@v3 - with: - path: ./wheelhouse/*.whl - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: wheelhouse/ - build_wheels_musl_aarch64_part_2: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - permissions: - id-token: write - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 - name: Install Python - with: - python-version: '3.8' - - uses: dtolnay/rust-toolchain@stable - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: all - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.16.2 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_ARCHS_LINUX: aarch64 - CIBW_SKIP: cp36-* cp37-* cp38-* cp39-* cp310-* *many* + CIBW_SKIP: cp36-* cp37-* *many* CIBW_TEST_SKIP: cp37-* cp38-* cp39-* cp310-* cp311-* cp312-* *many* - uses: actions/upload-artifact@v3 with: @@ -258,44 +183,7 @@ jobs: run: | python -m cibuildwheel --output-dir wheelhouse env: - CIBW_SKIP: cp36-* cp37-* cp39-* cp310-* cp311-* pp* *win32 - CIBW_ARCHS_LINUX: ppc64le - - uses: actions/upload-artifact@v3 - with: - path: ./wheelhouse/*.whl - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: wheelhouse/ - build_wheels_ppc64le_part2: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - permissions: - id-token: write - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 - name: Install Python - with: - python-version: '3.8' - - uses: dtolnay/rust-toolchain@stable - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: all - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.16.2 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_SKIP: cp36-* cp37-* cp38-* cp312-* pp* *win32 *musl* + CIBW_SKIP: cp36-* cp37-* pp* *win32 CIBW_ARCHS_LINUX: ppc64le - uses: actions/upload-artifact@v3 with: @@ -332,44 +220,7 @@ jobs: run: | python -m cibuildwheel --output-dir wheelhouse env: - CIBW_SKIP: cp36-* cp37-* cp39-* cp310-* cp311-* pp* *win32 *musl* - CIBW_ARCHS_LINUX: s390x - - uses: actions/upload-artifact@v3 - with: - path: ./wheelhouse/*.whl - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: wheelhouse/ - build_wheels_s390x_part2: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - permissions: - id-token: write - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 - name: Install Python - with: - python-version: '3.8' - - uses: dtolnay/rust-toolchain@stable - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: all - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.16.2 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_SKIP: cp36-* cp37-* cp38-* cp312-* pp* *win32 *musl* + CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* CIBW_ARCHS_LINUX: s390x - uses: actions/upload-artifact@v3 with: From 5da92e406a23e308043dbebed305e094a5639579 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sun, 21 Jan 2024 18:38:42 -0500 Subject: [PATCH 04/22] Trigger action on fork report --- .github/workflows/wheels.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index 2232205326..a7e5006345 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -2,8 +2,8 @@ name: Wheel Builds on: push: - tags: - - '*' + branches: [ stable-abi-work ] + jobs: rustworkx-core: name: Publish rustworkx-core From 519a6b1515d19ec8f515f08b0b3b66d35425e90e Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sun, 21 Jan 2024 18:40:09 -0500 Subject: [PATCH 05/22] Test action --- .github/workflows/wheels.yml | 4 +- .github/workflows/wheels_test2.yml | 300 +++++++++++++++++++++++++++++ 2 files changed, 302 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/wheels_test2.yml diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index a7e5006345..2232205326 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -2,8 +2,8 @@ name: Wheel Builds on: push: - branches: [ stable-abi-work ] - + tags: + - '*' jobs: rustworkx-core: name: Publish rustworkx-core diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml new file mode 100644 index 0000000000..d6c44fd66d --- /dev/null +++ b/.github/workflows/wheels_test2.yml @@ -0,0 +1,300 @@ +--- +name: Wheel Test Build +on: + push: + branches: [ stable-abi-work ] + +jobs: + rustworkx-core: + name: Publish rustworkx-core + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: dtolnay/rust-toolchain@stable + - name: Run cargo publish + run: | + cd rustworkx-core + cargo publish + env: + CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} + sdist: + name: Build sdist + runs-on: ubuntu-latest + environment: release + permissions: + id-token: write + needs: ["upload_shared_wheels"] + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + name: Install Python + with: + python-version: '3.8' + - name: Install deps + run: pip install -U setuptools-rust + - name: Build sdist + run: python setup.py sdist + - uses: actions/upload-artifact@v3 + with: + path: ./dist/* + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + build_wheels: + name: Build wheels on ${{ matrix.os }} + runs-on: ${{ matrix.os }} + environment: release + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, windows-latest, macos-latest] + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + name: Install Python + with: + python-version: '3.8' + - uses: dtolnay/rust-toolchain@stable + - name: Install cibuildwheel + run: | + python -m pip install cibuildwheel==2.16.2 + - name: Build wheels + run: | + python -m cibuildwheel --output-dir wheelhouse + - uses: actions/upload-artifact@v3 + with: + path: ./wheelhouse/*.whl + name: shared-wheel-builds + upload_shared_wheels: + name: Upload shared build wheels + runs-on: ubuntu-latest + environment: release + permissions: + id-token: write + needs: ["build_wheels", "build-mac-arm-wheels", "build-win32-wheels"] + steps: + - uses: actions/download-artifact@v3 + with: + name: shared-wheel-builds + path: deploy + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: deploy + build_wheels_aarch64: + name: Build wheels on ${{ matrix.os }} + runs-on: ${{ matrix.os }} + environment: release + permissions: + id-token: write + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest] + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + name: Install Python + with: + python-version: '3.8' + - uses: dtolnay/rust-toolchain@stable + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + with: + platforms: all + - name: Install cibuildwheel + run: | + python -m pip install cibuildwheel==2.16.2 + - name: Build wheels + run: | + python -m cibuildwheel --output-dir wheelhouse + env: + CIBW_ARCHS_LINUX: aarch64 + CIBW_SKIP: cp36-* cp37-* pp* *musl* + - uses: actions/upload-artifact@v3 + with: + path: ./wheelhouse/*.whl + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: wheelhouse/ + build_wheels_musl_aarch64: + name: Build wheels on ${{ matrix.os }} + runs-on: ${{ matrix.os }} + environment: release + permissions: + id-token: write + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest] + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + name: Install Python + with: + python-version: '3.8' + - uses: dtolnay/rust-toolchain@stable + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + with: + platforms: all + - name: Install cibuildwheel + run: | + python -m pip install cibuildwheel==2.16.2 + - name: Build wheels + run: | + python -m cibuildwheel --output-dir wheelhouse + env: + CIBW_ARCHS_LINUX: aarch64 + CIBW_SKIP: cp36-* cp37-* *many* + CIBW_TEST_SKIP: cp37-* cp38-* cp39-* cp310-* cp311-* cp312-* *many* + - uses: actions/upload-artifact@v3 + with: + path: ./wheelhouse/*.whl + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: wheelhouse/ + build_wheels_ppc64le: + name: Build wheels on ${{ matrix.os }} + runs-on: ${{ matrix.os }} + environment: release + permissions: + id-token: write + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest] + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + name: Install Python + with: + python-version: '3.8' + - uses: dtolnay/rust-toolchain@stable + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + with: + platforms: all + - name: Install cibuildwheel + run: | + python -m pip install cibuildwheel==2.16.2 + - name: Build wheels + run: | + python -m cibuildwheel --output-dir wheelhouse + env: + CIBW_SKIP: cp36-* cp37-* pp* *win32 + CIBW_ARCHS_LINUX: ppc64le + - uses: actions/upload-artifact@v3 + with: + path: ./wheelhouse/*.whl + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: wheelhouse/ + build_wheels_s390x: + name: Build wheels on ${{ matrix.os }} + runs-on: ${{ matrix.os }} + environment: release + permissions: + id-token: write + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest] + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + name: Install Python + with: + python-version: '3.8' + - uses: dtolnay/rust-toolchain@stable + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + with: + platforms: all + - name: Install cibuildwheel + run: | + python -m pip install cibuildwheel==2.16.2 + - name: Build wheels + run: | + python -m cibuildwheel --output-dir wheelhouse + env: + CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* + CIBW_ARCHS_LINUX: s390x + - uses: actions/upload-artifact@v3 + with: + path: ./wheelhouse/*.whl + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: wheelhouse/ + build-mac-arm-wheels: + name: Build wheels on macos for arm and universal2 + runs-on: macos-latest + environment: release + steps: + - uses: actions/checkout@v3 + - name: Build wheels + uses: joerick/cibuildwheel@v2.16.2 + env: + CIBW_BEFORE_ALL: rustup target add aarch64-apple-darwin + CIBW_ARCHS_MACOS: arm64 universal2 + CIBW_BEFORE_BUILD: pip install -U setuptools-rust + CIBW_ENVIRONMENT: CARGO_BUILD_TARGET="aarch64-apple-darwin" PYO3_CROSS_LIB_DIR="/Library/Frameworks/Python.framework/Versions/$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')/lib/python$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')" + - uses: actions/upload-artifact@v3 + with: + path: ./wheelhouse/*.whl + name: shared-wheel-builds + build-win32-wheels: + name: Build wheels on win32 + runs-on: windows-latest + environment: release + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + name: Install Python + with: + python-version: '3.8' + architecture: 'x86' + - uses: dtolnay/rust-toolchain@stable + with: + targets: i686-pc-windows-msvc + - name: Force win32 rust + run: rustup default stable-i686-pc-windows-msvc + - name: Install cibuildwheel + run: | + python -m pip install cibuildwheel==2.16.2 + - name: Build wheels + run: | + python -m cibuildwheel --output-dir wheelhouse + env: + CIBW_SKIP: cp36-* cp37-* pp* *amd64 *musl* + - uses: actions/upload-artifact@v3 + with: + path: ./wheelhouse/*.whl + name: shared-wheel-builds + retworkx-compat-build: + name: Build retworkx + runs-on: ubuntu-latest + environment: release + permissions: + id-token: write + needs: ["upload_shared_wheels"] + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + name: Install Python + with: + python-version: '3.10' + - name: Install deps + run: pip install -U setuptools-rust wheel build + - name: Build sdist + run: python setup.py bdist_wheel + env: + RUSTWORKX_PKG_NAME: retworkx + - uses: actions/upload-artifact@v3 + with: + path: ./dist/* + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 From 32e6886502654180f71919d291b66a6947a5a435 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Wed, 24 Jan 2024 00:11:16 -0500 Subject: [PATCH 06/22] Skip musl in ppc64 --- .github/workflows/wheels.yml | 2 +- .github/workflows/wheels_test2.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index 2232205326..d648a176be 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -183,7 +183,7 @@ jobs: run: | python -m cibuildwheel --output-dir wheelhouse env: - CIBW_SKIP: cp36-* cp37-* pp* *win32 + CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* CIBW_ARCHS_LINUX: ppc64le - uses: actions/upload-artifact@v3 with: diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index d6c44fd66d..4299f17215 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -183,7 +183,7 @@ jobs: run: | python -m cibuildwheel --output-dir wheelhouse env: - CIBW_SKIP: cp36-* cp37-* pp* *win32 + CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* CIBW_ARCHS_LINUX: ppc64le - uses: actions/upload-artifact@v3 with: From 2a26db6d0fe8497e7030066061d5117251cffecd Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Thu, 21 Mar 2024 05:25:02 -0400 Subject: [PATCH 07/22] Restore abi-py38 --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 11554068a7..cc209ebfac 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -61,7 +61,7 @@ rustworkx-core = { path = "rustworkx-core", version = "=0.15.0" } [dependencies.pyo3] version = "0.20.3" -features = ["extension-module", "hashbrown", "num-bigint", "num-complex", "indexmap"] +features = ["abi3-py38", "extension-module", "hashbrown", "num-bigint", "num-complex", "indexmap"] [dependencies.ndarray] version = "^0.15.6" From 27df55e8f18858f117a5ab91ca9f88cbd33ce212 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Thu, 21 Mar 2024 05:29:18 -0400 Subject: [PATCH 08/22] Version bumps --- .github/workflows/wheels.yml | 54 +++++++++++++++--------------- .github/workflows/wheels_test2.yml | 54 +++++++++++++++--------------- 2 files changed, 54 insertions(+), 54 deletions(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index d648a176be..d1d4c8ec3c 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -9,7 +9,7 @@ jobs: name: Publish rustworkx-core runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable - name: Run cargo publish run: | @@ -25,8 +25,8 @@ jobs: id-token: write needs: ["upload_shared_wheels"] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -34,7 +34,7 @@ jobs: run: pip install -U setuptools-rust - name: Build sdist run: python setup.py sdist - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./dist/* - name: Publish package distributions to PyPI @@ -48,8 +48,8 @@ jobs: matrix: os: [ubuntu-latest, windows-latest, macos-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -60,7 +60,7 @@ jobs: - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl name: shared-wheel-builds @@ -91,8 +91,8 @@ jobs: matrix: os: [ubuntu-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -110,7 +110,7 @@ jobs: env: CIBW_ARCHS_LINUX: aarch64 CIBW_SKIP: cp36-* cp37-* pp* *musl* - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: Publish package distributions to PyPI @@ -128,8 +128,8 @@ jobs: matrix: os: [ubuntu-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -148,7 +148,7 @@ jobs: CIBW_ARCHS_LINUX: aarch64 CIBW_SKIP: cp36-* cp37-* *many* CIBW_TEST_SKIP: cp37-* cp38-* cp39-* cp310-* cp311-* cp312-* *many* - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: Publish package distributions to PyPI @@ -166,8 +166,8 @@ jobs: matrix: os: [ubuntu-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -185,7 +185,7 @@ jobs: env: CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* CIBW_ARCHS_LINUX: ppc64le - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: Publish package distributions to PyPI @@ -203,8 +203,8 @@ jobs: matrix: os: [ubuntu-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -222,7 +222,7 @@ jobs: env: CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* CIBW_ARCHS_LINUX: s390x - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: Publish package distributions to PyPI @@ -234,7 +234,7 @@ jobs: runs-on: macos-latest environment: release steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Build wheels uses: joerick/cibuildwheel@v2.16.2 env: @@ -242,7 +242,7 @@ jobs: CIBW_ARCHS_MACOS: arm64 universal2 CIBW_BEFORE_BUILD: pip install -U setuptools-rust CIBW_ENVIRONMENT: CARGO_BUILD_TARGET="aarch64-apple-darwin" PYO3_CROSS_LIB_DIR="/Library/Frameworks/Python.framework/Versions/$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')/lib/python$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')" - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl name: shared-wheel-builds @@ -251,8 +251,8 @@ jobs: runs-on: windows-latest environment: release steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -270,7 +270,7 @@ jobs: python -m cibuildwheel --output-dir wheelhouse env: CIBW_SKIP: cp36-* cp37-* pp* *amd64 *musl* - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl name: shared-wheel-builds @@ -282,8 +282,8 @@ jobs: id-token: write needs: ["upload_shared_wheels"] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.10' @@ -293,7 +293,7 @@ jobs: run: python setup.py bdist_wheel env: RUSTWORKX_PKG_NAME: retworkx - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./dist/* - name: Publish package distributions to PyPI diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index 4299f17215..789bfff8a4 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -9,7 +9,7 @@ jobs: name: Publish rustworkx-core runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable - name: Run cargo publish run: | @@ -25,8 +25,8 @@ jobs: id-token: write needs: ["upload_shared_wheels"] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -34,7 +34,7 @@ jobs: run: pip install -U setuptools-rust - name: Build sdist run: python setup.py sdist - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./dist/* - name: Publish package distributions to PyPI @@ -48,8 +48,8 @@ jobs: matrix: os: [ubuntu-latest, windows-latest, macos-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -60,7 +60,7 @@ jobs: - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl name: shared-wheel-builds @@ -91,8 +91,8 @@ jobs: matrix: os: [ubuntu-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -110,7 +110,7 @@ jobs: env: CIBW_ARCHS_LINUX: aarch64 CIBW_SKIP: cp36-* cp37-* pp* *musl* - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: Publish package distributions to PyPI @@ -128,8 +128,8 @@ jobs: matrix: os: [ubuntu-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -148,7 +148,7 @@ jobs: CIBW_ARCHS_LINUX: aarch64 CIBW_SKIP: cp36-* cp37-* *many* CIBW_TEST_SKIP: cp37-* cp38-* cp39-* cp310-* cp311-* cp312-* *many* - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: Publish package distributions to PyPI @@ -166,8 +166,8 @@ jobs: matrix: os: [ubuntu-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -185,7 +185,7 @@ jobs: env: CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* CIBW_ARCHS_LINUX: ppc64le - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: Publish package distributions to PyPI @@ -203,8 +203,8 @@ jobs: matrix: os: [ubuntu-latest] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -222,7 +222,7 @@ jobs: env: CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* CIBW_ARCHS_LINUX: s390x - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: Publish package distributions to PyPI @@ -234,7 +234,7 @@ jobs: runs-on: macos-latest environment: release steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Build wheels uses: joerick/cibuildwheel@v2.16.2 env: @@ -242,7 +242,7 @@ jobs: CIBW_ARCHS_MACOS: arm64 universal2 CIBW_BEFORE_BUILD: pip install -U setuptools-rust CIBW_ENVIRONMENT: CARGO_BUILD_TARGET="aarch64-apple-darwin" PYO3_CROSS_LIB_DIR="/Library/Frameworks/Python.framework/Versions/$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')/lib/python$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')" - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl name: shared-wheel-builds @@ -251,8 +251,8 @@ jobs: runs-on: windows-latest environment: release steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.8' @@ -270,7 +270,7 @@ jobs: python -m cibuildwheel --output-dir wheelhouse env: CIBW_SKIP: cp36-* cp37-* pp* *amd64 *musl* - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl name: shared-wheel-builds @@ -282,8 +282,8 @@ jobs: id-token: write needs: ["upload_shared_wheels"] steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 name: Install Python with: python-version: '3.10' @@ -293,7 +293,7 @@ jobs: run: python setup.py bdist_wheel env: RUSTWORKX_PKG_NAME: retworkx - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./dist/* - name: Publish package distributions to PyPI From c5046afe3e6f900821a77f227d3029854aa4fd26 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Thu, 21 Mar 2024 05:41:53 -0400 Subject: [PATCH 09/22] Take into account Mac OS ARM changes --- .github/workflows/wheels.yml | 47 ++++++++++-------------------- .github/workflows/wheels_test2.yml | 45 +++++++++------------------- pyproject.toml | 1 + 3 files changed, 30 insertions(+), 63 deletions(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index d1d4c8ec3c..1b4aa8f82f 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -29,7 +29,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - name: Install deps run: pip install -U setuptools-rust - name: Build sdist @@ -46,17 +46,17 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-latest, windows-latest, macos-latest] + os: [ubuntu-latest, windows-latest, macos-latest, macos-14] steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -70,7 +70,7 @@ jobs: environment: release permissions: id-token: write - needs: ["build_wheels", "build-mac-arm-wheels", "build-win32-wheels"] + needs: ["build_wheels", "build-win32-wheels"] steps: - uses: actions/download-artifact@v3 with: @@ -95,7 +95,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -103,7 +103,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -132,7 +132,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -140,7 +140,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -170,7 +170,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -178,7 +178,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -207,7 +207,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -215,7 +215,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -229,23 +229,6 @@ jobs: uses: pypa/gh-action-pypi-publish@release/v1 with: packages-dir: wheelhouse/ - build-mac-arm-wheels: - name: Build wheels on macos for arm and universal2 - runs-on: macos-latest - environment: release - steps: - - uses: actions/checkout@v4 - - name: Build wheels - uses: joerick/cibuildwheel@v2.16.2 - env: - CIBW_BEFORE_ALL: rustup target add aarch64-apple-darwin - CIBW_ARCHS_MACOS: arm64 universal2 - CIBW_BEFORE_BUILD: pip install -U setuptools-rust - CIBW_ENVIRONMENT: CARGO_BUILD_TARGET="aarch64-apple-darwin" PYO3_CROSS_LIB_DIR="/Library/Frameworks/Python.framework/Versions/$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')/lib/python$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')" - - uses: actions/upload-artifact@v4 - with: - path: ./wheelhouse/*.whl - name: shared-wheel-builds build-win32-wheels: name: Build wheels on win32 runs-on: windows-latest @@ -255,7 +238,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' architecture: 'x86' - uses: dtolnay/rust-toolchain@stable with: @@ -264,7 +247,7 @@ jobs: run: rustup default stable-i686-pc-windows-msvc - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index 789bfff8a4..be369b1483 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -29,7 +29,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - name: Install deps run: pip install -U setuptools-rust - name: Build sdist @@ -46,17 +46,17 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-latest, windows-latest, macos-latest] + os: [ubuntu-latest, windows-latest, macos-latest, macos-14] steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -95,7 +95,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -103,7 +103,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -132,7 +132,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -140,7 +140,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -170,7 +170,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -178,7 +178,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -207,7 +207,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' - uses: dtolnay/rust-toolchain@stable - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -215,7 +215,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -229,23 +229,6 @@ jobs: uses: pypa/gh-action-pypi-publish@release/v1 with: packages-dir: wheelhouse/ - build-mac-arm-wheels: - name: Build wheels on macos for arm and universal2 - runs-on: macos-latest - environment: release - steps: - - uses: actions/checkout@v4 - - name: Build wheels - uses: joerick/cibuildwheel@v2.16.2 - env: - CIBW_BEFORE_ALL: rustup target add aarch64-apple-darwin - CIBW_ARCHS_MACOS: arm64 universal2 - CIBW_BEFORE_BUILD: pip install -U setuptools-rust - CIBW_ENVIRONMENT: CARGO_BUILD_TARGET="aarch64-apple-darwin" PYO3_CROSS_LIB_DIR="/Library/Frameworks/Python.framework/Versions/$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')/lib/python$(python -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))')" - - uses: actions/upload-artifact@v4 - with: - path: ./wheelhouse/*.whl - name: shared-wheel-builds build-win32-wheels: name: Build wheels on win32 runs-on: windows-latest @@ -255,7 +238,7 @@ jobs: - uses: actions/setup-python@v5 name: Install Python with: - python-version: '3.8' + python-version: '3.10' architecture: 'x86' - uses: dtolnay/rust-toolchain@stable with: @@ -264,7 +247,7 @@ jobs: run: rustup default stable-i686-pc-windows-msvc - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.2 + python -m pip install cibuildwheel==2.16.5 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse diff --git a/pyproject.toml b/pyproject.toml index 92de906ba3..9725120904 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -35,6 +35,7 @@ test-skip = "cp38-*musllinux* *linux_s390x *ppc64le" [tool.cibuildwheel.linux] before-all = "yum install -y wget && {package}/tools/install_rust.sh" environment = 'PATH="$PATH:$HOME/.cargo/bin" CARGO_NET_GIT_FETCH_WITH_CLI="true"' +repair-wheel-command = "auditwheel repair -w {dest_dir} {wheel} && pipx run abi3audit --strict --report {wheel}" [[tool.cibuildwheel.overrides]] select = "*-musllinux*" From 11049ac426c61ecd0269905eba383f16722546fc Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Thu, 21 Mar 2024 05:51:50 -0400 Subject: [PATCH 10/22] Testing build process --- .github/workflows/wheels_test2.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index be369b1483..d815dba3be 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -3,7 +3,6 @@ name: Wheel Test Build on: push: branches: [ stable-abi-work ] - jobs: rustworkx-core: name: Publish rustworkx-core @@ -70,7 +69,7 @@ jobs: environment: release permissions: id-token: write - needs: ["build_wheels", "build-mac-arm-wheels", "build-win32-wheels"] + needs: ["build_wheels", "build-win32-wheels"] steps: - uses: actions/download-artifact@v3 with: From fb69db8090a235244b97341a95caa25ec8731ad8 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Fri, 22 Mar 2024 18:23:26 -0400 Subject: [PATCH 11/22] Re-triggering workflow --- .github/workflows/wheels_test2.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index d815dba3be..d1df42bae9 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -13,7 +13,7 @@ jobs: - name: Run cargo publish run: | cd rustworkx-core - cargo publish + # cargo publish env: CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} sdist: From fdf058f83a8af759d9b8fe06c53903187930ba95 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Fri, 22 Mar 2024 18:55:39 -0400 Subject: [PATCH 12/22] Try again --- .github/workflows/wheels.yml | 7 ++++--- .github/workflows/wheels_test2.yml | 9 +++++---- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index 1b4aa8f82f..cc1bc6cded 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -63,7 +63,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: shared-wheel-builds + name: shared-wheel-builds-${{ matrix.runs-on }} upload_shared_wheels: name: Upload shared build wheels runs-on: ubuntu-latest @@ -74,7 +74,8 @@ jobs: steps: - uses: actions/download-artifact@v3 with: - name: shared-wheel-builds + pattern: shared-wheel-builds-* + merge-multiple: true path: deploy - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 @@ -256,7 +257,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: shared-wheel-builds + name: shared-wheel-builds-win32 retworkx-compat-build: name: Build retworkx runs-on: ubuntu-latest diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index d1df42bae9..c8fa5df98f 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -62,7 +62,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: shared-wheel-builds + name: shared-wheel-builds-${{ matrix.runs-on }} upload_shared_wheels: name: Upload shared build wheels runs-on: ubuntu-latest @@ -73,7 +73,8 @@ jobs: steps: - uses: actions/download-artifact@v3 with: - name: shared-wheel-builds + pattern: shared-wheel-builds-* + merge-multiple: true path: deploy - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 @@ -255,7 +256,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: shared-wheel-builds + name: shared-wheel-builds-win32 retworkx-compat-build: name: Build retworkx runs-on: ubuntu-latest @@ -279,4 +280,4 @@ jobs: with: path: ./dist/* - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 + uses: pypa/gh-action-pypi-publish@release/v1 \ No newline at end of file From dfd99de791e439261702440019b618476be759e3 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 02:03:40 -0400 Subject: [PATCH 13/22] Fix upload v4 use --- .github/workflows/wheels.yml | 2 +- .github/workflows/wheels_test2.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index cc1bc6cded..ce0770d318 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -63,7 +63,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: shared-wheel-builds-${{ matrix.runs-on }} + name: shared-wheel-builds-${{ matrix.os }} upload_shared_wheels: name: Upload shared build wheels runs-on: ubuntu-latest diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index c8fa5df98f..261cce1b6b 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -62,7 +62,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl - name: shared-wheel-builds-${{ matrix.runs-on }} + name: shared-wheel-builds-${{ matrix.os }} upload_shared_wheels: name: Upload shared build wheels runs-on: ubuntu-latest From bbb9a629c05543603409dc881571898d447f0407 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 02:21:03 -0400 Subject: [PATCH 14/22] Fix all upload uses --- .github/workflows/wheels.yml | 6 ++++++ .github/workflows/wheels_test2.yml | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index ce0770d318..c8072a99f9 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -37,6 +37,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./dist/* + name: sdist-rustworkx - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 build_wheels: @@ -114,6 +115,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl + name: wheel-builds-aarch64 - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: @@ -152,6 +154,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl + name: wheel-builds-musl-aarch64 - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: @@ -189,6 +192,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl + name: wheel-builds-ppc64le - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: @@ -226,6 +230,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl + name: wheel-builds-s390x - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: @@ -280,5 +285,6 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./dist/* + name: sdist-retworkx - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index 261cce1b6b..f8781b3492 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -36,6 +36,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./dist/* + name: sdist-rustworkx - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 build_wheels: @@ -113,6 +114,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl + name: wheel-builds-aarch64 - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: @@ -151,6 +153,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl + name: wheel-builds-musl-aarch64 - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: @@ -188,6 +191,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl + name: wheel-builds-ppc64le - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: @@ -225,6 +229,7 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./wheelhouse/*.whl + name: wheel-builds-s390x - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: @@ -279,5 +284,6 @@ jobs: - uses: actions/upload-artifact@v4 with: path: ./dist/* + name: sdist-retworkx - name: Publish package distributions to PyPI uses: pypa/gh-action-pypi-publish@release/v1 \ No newline at end of file From 6b9191f6f37ba800b44206b06faa6bf9bd84becd Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 02:38:05 -0400 Subject: [PATCH 15/22] Repair wheels for macos and windows as well --- pyproject.toml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 9725120904..ea79d8b145 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,3 +47,7 @@ before-test = 'python -m pip install numpy --config-settings=setup-args="-Dallow [tool.cibuildwheel.macos] environment = "MACOSX_DEPLOYMENT_TARGET=10.12" +repair-wheel-command = "delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel} && pipx run abi3audit --strict --report {wheel}" + +[tool.cibuildwheel.windows] +repair-wheel-command = "cp {wheel} {dest_dir}/. && pipx run abi3audit --strict --report {wheel}" \ No newline at end of file From 13c28d998c62f26037471fdda5eea9e6c4bc049f Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 02:43:30 -0400 Subject: [PATCH 16/22] Use fixed version of abi3audit --- pyproject.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index ea79d8b145..7260c100f2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -35,7 +35,7 @@ test-skip = "cp38-*musllinux* *linux_s390x *ppc64le" [tool.cibuildwheel.linux] before-all = "yum install -y wget && {package}/tools/install_rust.sh" environment = 'PATH="$PATH:$HOME/.cargo/bin" CARGO_NET_GIT_FETCH_WITH_CLI="true"' -repair-wheel-command = "auditwheel repair -w {dest_dir} {wheel} && pipx run abi3audit --strict --report {wheel}" +repair-wheel-command = "auditwheel repair -w {dest_dir} {wheel} && pipx run abi3audit==0.0.9 --strict --report {wheel}" [[tool.cibuildwheel.overrides]] select = "*-musllinux*" @@ -47,7 +47,7 @@ before-test = 'python -m pip install numpy --config-settings=setup-args="-Dallow [tool.cibuildwheel.macos] environment = "MACOSX_DEPLOYMENT_TARGET=10.12" -repair-wheel-command = "delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel} && pipx run abi3audit --strict --report {wheel}" +repair-wheel-command = "delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel} && pipx run abi3audit==0.0.9 --strict --report {wheel}" [tool.cibuildwheel.windows] -repair-wheel-command = "cp {wheel} {dest_dir}/. && pipx run abi3audit --strict --report {wheel}" \ No newline at end of file +repair-wheel-command = "cp {wheel} {dest_dir}/. && pipx run abi3audit==0.0.9 --strict --report {wheel}" \ No newline at end of file From 4b49f6a88acfe663437f3cc1b2c6f31033e16848 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 02:44:46 -0400 Subject: [PATCH 17/22] Use cibuildwheel 2.17.0 --- .github/workflows/wheels.yml | 12 ++++++------ .github/workflows/wheels_test2.yml | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index c8072a99f9..331ae0dba5 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -57,7 +57,7 @@ jobs: - uses: dtolnay/rust-toolchain@stable - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -105,7 +105,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -143,7 +143,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -182,7 +182,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -220,7 +220,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -253,7 +253,7 @@ jobs: run: rustup default stable-i686-pc-windows-msvc - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index f8781b3492..9e53fc893a 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -56,7 +56,7 @@ jobs: - uses: dtolnay/rust-toolchain@stable - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -104,7 +104,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -142,7 +142,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -181,7 +181,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -219,7 +219,7 @@ jobs: platforms: all - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse @@ -252,7 +252,7 @@ jobs: run: rustup default stable-i686-pc-windows-msvc - name: Install cibuildwheel run: | - python -m pip install cibuildwheel==2.16.5 + python -m pip install cibuildwheel==2.17.0 - name: Build wheels run: | python -m cibuildwheel --output-dir wheelhouse From fbad224c605aae17c8bfef23ad700f96bb8d4ace Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 02:55:26 -0400 Subject: [PATCH 18/22] Handle delocate not being installed --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7260c100f2..85939ae9bd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,7 @@ before-test = 'python -m pip install numpy --config-settings=setup-args="-Dallow [tool.cibuildwheel.macos] environment = "MACOSX_DEPLOYMENT_TARGET=10.12" -repair-wheel-command = "delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel} && pipx run abi3audit==0.0.9 --strict --report {wheel}" +repair-wheel-command = "pipx run --spec delocate==0.11.0 delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel} && pipx run abi3audit==0.0.9 --strict --report {wheel}" [tool.cibuildwheel.windows] repair-wheel-command = "cp {wheel} {dest_dir}/. && pipx run abi3audit==0.0.9 --strict --report {wheel}" \ No newline at end of file From 95a50e29edd856f06e2215a5884c1bf77fbfdba2 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 03:02:30 -0400 Subject: [PATCH 19/22] Handle pipx in macOS arm --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 85939ae9bd..a7da3f16cc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,7 @@ before-test = 'python -m pip install numpy --config-settings=setup-args="-Dallow [tool.cibuildwheel.macos] environment = "MACOSX_DEPLOYMENT_TARGET=10.12" -repair-wheel-command = "pipx run --spec delocate==0.11.0 delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel} && pipx run abi3audit==0.0.9 --strict --report {wheel}" +repair-wheel-command = "brew install pipx && pipx ensurepath && pipx run --spec delocate==0.11.0 delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel} && pipx run abi3audit==0.0.9 --strict --report {wheel}" [tool.cibuildwheel.windows] repair-wheel-command = "cp {wheel} {dest_dir}/. && pipx run abi3audit==0.0.9 --strict --report {wheel}" \ No newline at end of file From c9ed25db55e2e84c001e89ca4f4b2a8aec714905 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho <8753214+IvanIsCoding@users.noreply.github.com> Date: Sat, 23 Mar 2024 04:01:51 -0400 Subject: [PATCH 20/22] Update wheels.yml --- .github/workflows/wheels.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index 331ae0dba5..b8328e0631 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -73,7 +73,7 @@ jobs: id-token: write needs: ["build_wheels", "build-win32-wheels"] steps: - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: pattern: shared-wheel-builds-* merge-multiple: true From 808b4f4963062eb9989f9363610936212984b98a Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 05:00:39 -0400 Subject: [PATCH 21/22] Test download-artifact v4 --- .github/workflows/wheels_test2.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml index 9e53fc893a..bae1b5e9ed 100644 --- a/.github/workflows/wheels_test2.yml +++ b/.github/workflows/wheels_test2.yml @@ -72,7 +72,7 @@ jobs: id-token: write needs: ["build_wheels", "build-win32-wheels"] steps: - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: pattern: shared-wheel-builds-* merge-multiple: true From 039ceefa499725d855703036e8fbaabd4d500803 Mon Sep 17 00:00:00 2001 From: Ivan Carvalho Date: Sat, 23 Mar 2024 06:14:59 -0400 Subject: [PATCH 22/22] Add release notes --- .github/workflows/wheels_test2.yml | 289 ------------------ .../stable-abi-python-4c883bc4edaf8354.yaml | 9 + 2 files changed, 9 insertions(+), 289 deletions(-) delete mode 100644 .github/workflows/wheels_test2.yml create mode 100644 releasenotes/notes/stable-abi-python-4c883bc4edaf8354.yaml diff --git a/.github/workflows/wheels_test2.yml b/.github/workflows/wheels_test2.yml deleted file mode 100644 index bae1b5e9ed..0000000000 --- a/.github/workflows/wheels_test2.yml +++ /dev/null @@ -1,289 +0,0 @@ ---- -name: Wheel Test Build -on: - push: - branches: [ stable-abi-work ] -jobs: - rustworkx-core: - name: Publish rustworkx-core - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: dtolnay/rust-toolchain@stable - - name: Run cargo publish - run: | - cd rustworkx-core - # cargo publish - env: - CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} - sdist: - name: Build sdist - runs-on: ubuntu-latest - environment: release - permissions: - id-token: write - needs: ["upload_shared_wheels"] - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - name: Install Python - with: - python-version: '3.10' - - name: Install deps - run: pip install -U setuptools-rust - - name: Build sdist - run: python setup.py sdist - - uses: actions/upload-artifact@v4 - with: - path: ./dist/* - name: sdist-rustworkx - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - build_wheels: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest, windows-latest, macos-latest, macos-14] - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - name: Install Python - with: - python-version: '3.10' - - uses: dtolnay/rust-toolchain@stable - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.17.0 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - - uses: actions/upload-artifact@v4 - with: - path: ./wheelhouse/*.whl - name: shared-wheel-builds-${{ matrix.os }} - upload_shared_wheels: - name: Upload shared build wheels - runs-on: ubuntu-latest - environment: release - permissions: - id-token: write - needs: ["build_wheels", "build-win32-wheels"] - steps: - - uses: actions/download-artifact@v4 - with: - pattern: shared-wheel-builds-* - merge-multiple: true - path: deploy - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: deploy - build_wheels_aarch64: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - permissions: - id-token: write - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - name: Install Python - with: - python-version: '3.10' - - uses: dtolnay/rust-toolchain@stable - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: all - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.17.0 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_ARCHS_LINUX: aarch64 - CIBW_SKIP: cp36-* cp37-* pp* *musl* - - uses: actions/upload-artifact@v4 - with: - path: ./wheelhouse/*.whl - name: wheel-builds-aarch64 - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: wheelhouse/ - build_wheels_musl_aarch64: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - permissions: - id-token: write - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - name: Install Python - with: - python-version: '3.10' - - uses: dtolnay/rust-toolchain@stable - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: all - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.17.0 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_ARCHS_LINUX: aarch64 - CIBW_SKIP: cp36-* cp37-* *many* - CIBW_TEST_SKIP: cp37-* cp38-* cp39-* cp310-* cp311-* cp312-* *many* - - uses: actions/upload-artifact@v4 - with: - path: ./wheelhouse/*.whl - name: wheel-builds-musl-aarch64 - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: wheelhouse/ - build_wheels_ppc64le: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - permissions: - id-token: write - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - name: Install Python - with: - python-version: '3.10' - - uses: dtolnay/rust-toolchain@stable - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: all - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.17.0 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* - CIBW_ARCHS_LINUX: ppc64le - - uses: actions/upload-artifact@v4 - with: - path: ./wheelhouse/*.whl - name: wheel-builds-ppc64le - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: wheelhouse/ - build_wheels_s390x: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} - environment: release - permissions: - id-token: write - strategy: - fail-fast: false - matrix: - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - name: Install Python - with: - python-version: '3.10' - - uses: dtolnay/rust-toolchain@stable - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: all - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.17.0 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_SKIP: cp36-* cp37-* pp* *win32 *musl* - CIBW_ARCHS_LINUX: s390x - - uses: actions/upload-artifact@v4 - with: - path: ./wheelhouse/*.whl - name: wheel-builds-s390x - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: wheelhouse/ - build-win32-wheels: - name: Build wheels on win32 - runs-on: windows-latest - environment: release - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - name: Install Python - with: - python-version: '3.10' - architecture: 'x86' - - uses: dtolnay/rust-toolchain@stable - with: - targets: i686-pc-windows-msvc - - name: Force win32 rust - run: rustup default stable-i686-pc-windows-msvc - - name: Install cibuildwheel - run: | - python -m pip install cibuildwheel==2.17.0 - - name: Build wheels - run: | - python -m cibuildwheel --output-dir wheelhouse - env: - CIBW_SKIP: cp36-* cp37-* pp* *amd64 *musl* - - uses: actions/upload-artifact@v4 - with: - path: ./wheelhouse/*.whl - name: shared-wheel-builds-win32 - retworkx-compat-build: - name: Build retworkx - runs-on: ubuntu-latest - environment: release - permissions: - id-token: write - needs: ["upload_shared_wheels"] - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - name: Install Python - with: - python-version: '3.10' - - name: Install deps - run: pip install -U setuptools-rust wheel build - - name: Build sdist - run: python setup.py bdist_wheel - env: - RUSTWORKX_PKG_NAME: retworkx - - uses: actions/upload-artifact@v4 - with: - path: ./dist/* - name: sdist-retworkx - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 \ No newline at end of file diff --git a/releasenotes/notes/stable-abi-python-4c883bc4edaf8354.yaml b/releasenotes/notes/stable-abi-python-4c883bc4edaf8354.yaml new file mode 100644 index 0000000000..5b06382d07 --- /dev/null +++ b/releasenotes/notes/stable-abi-python-4c883bc4edaf8354.yaml @@ -0,0 +1,9 @@ +--- +features: + - | + rustworkx wheels are now built against Python's stable + Application Binary Interface (ABI). For rustworkx users, this means + that wheels distributed by us via PyPI will continue to work with + newer versions of Python without having to recompile the code. + This change will also simplify the release process for the developers + and reduce the storage size required to mirror rustworkx wheels.