You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iceberg.apache.org by sc...@apache.org on 2026/04/29 23:48:31 UTC

(iceberg-rust) branch main updated: ci(python): verify wheel abi3 compatibility with --no-build (#2388)

This is an automated email from the ASF dual-hosted git repository.

CTTY pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/iceberg-rust.git


The following commit(s) were added to refs/heads/main by this push:
     new 976b689dd ci(python): verify wheel abi3 compatibility with --no-build (#2388)
976b689dd is described below

commit 976b689dd311c40986f72d98b95daccb5da37ef5
Author: Kevin Liu <ke...@users.noreply.github.com>
AuthorDate: Wed Apr 29 19:48:25 2026 -0400

    ci(python): verify wheel abi3 compatibility with --no-build (#2388)
    
    ## Which issue does this PR close?
    
    <!--
    We generally require a GitHub issue to be filed for all bug fixes and
    enhancements and this helps us generate change logs for our releases.
    You can link an issue to this PR using the GitHub syntax. For example
    `Closes #123` indicates that this PR will close issue #123.
    -->
    
    - Closes #.
    
    ## What changes are included in this PR?
    Verify that `pyiceberg-core` does not need to be built when installing
    
    Adds a `uv pip install --no-build` check after maturin builds to verify
    the produced wheel is abi3-compatible with Python 3.12.
    
    This prevents a repeat of
    https://github.com/apache/iceberg-python/issues/3190 where maturin
    picked Python 3.8 inside a manylinux container, producing a `cp38-cp38`
    wheel instead of `cp310-abi3`.
    **With `--no-build`, the install fails if the wheel isn't compatible —
    no fallback to source builds.**
    
    **Changes:**
    - `bindings_python_ci.yml`: use `--no-build` when installing the built
    wheel in CI
    - `release_python.yml` / `release_python_nightly.yml`: add verification
    step after each maturin build
    
    <!--
    Provide a summary of the modifications in this PR. List the main changes
    such as new features, bug fixes, refactoring, or any other updates.
    -->
    
    ## Are these changes tested?
    
    <!--
    Specify what test covers (unit test, integration test, etc.).
    
    If tests are not included in your PR, please explain why (for example,
    are they covered by existing tests)?
    -->
    
    Yes
    * .github/workflows/bindings_python_ci.yml in CI
    *
    [release_python.yml](https://github.com/kevinjqliu/iceberg-rust/actions/runs/25125359496)
    /
    [release_python_nightly.yml](https://github.com/kevinjqliu/iceberg-rust/actions/runs/25125566003)
    in fork
---
 .github/workflows/bindings_python_ci.yml     |  2 +-
 .github/workflows/release_python.yml         | 13 +++++++++++++
 .github/workflows/release_python_nightly.yml | 14 ++++++++++++++
 3 files changed, 28 insertions(+), 1 deletion(-)

diff --git a/.github/workflows/bindings_python_ci.yml b/.github/workflows/bindings_python_ci.yml
index 842fce7f8..e1c885357 100644
--- a/.github/workflows/bindings_python_ci.yml
+++ b/.github/workflows/bindings_python_ci.yml
@@ -113,7 +113,7 @@ jobs:
         working-directory: "bindings/python"
         shell: bash
         run: |
-          uv pip install --reinstall dist/pyiceberg_core-*.whl
+          uv pip install --no-build --reinstall --find-links dist/ pyiceberg-core
       - name: Run tests
         working-directory: "bindings/python"
         shell: bash
diff --git a/.github/workflows/release_python.yml b/.github/workflows/release_python.yml
index 0638cff6d..1961b2250 100644
--- a/.github/workflows/release_python.yml
+++ b/.github/workflows/release_python.yml
@@ -191,6 +191,19 @@ jobs:
           working-directory: "bindings/python"
           command: build
           args: --release -o dist -i python3.12 # Explicitly set interpreter; manylinux containers have multiple Pythons and maturin may pick an older one
+      - uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
+        with:
+          version: "0.9.3"
+          enable-cache: true
+      # Verify the wheel is abi3-compatible and installable without building from source.
+      # Skipped for cross-compiled targets since they share the same maturin config;
+      # if abi3 is broken, the native target build will catch it.
+      - name: Verify wheel installs with no build fallback
+        if: matrix.target != 'aarch64' && matrix.target != 'armv7l'
+        working-directory: "bindings/python"
+        shell: bash
+        run: |
+          uv pip install --no-build --reinstall --system --find-links dist/ pyiceberg-core
       - name: Upload wheels
         uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
         with:
diff --git a/.github/workflows/release_python_nightly.yml b/.github/workflows/release_python_nightly.yml
index 26b034554..1dd6c8e2a 100644
--- a/.github/workflows/release_python_nightly.yml
+++ b/.github/workflows/release_python_nightly.yml
@@ -106,6 +106,20 @@ jobs:
           command: build
           args: --release -o dist -i python3.12 # Explicitly set interpreter; manylinux containers have multiple Pythons and maturin may pick an older one
 
+      - uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
+        with:
+          version: "0.9.3"
+          enable-cache: true
+      # Verify the wheel is abi3-compatible and installable without building from source.
+      # Skipped for cross-compiled targets since they share the same maturin config;
+      # if abi3 is broken, the native target build will catch it.
+      - name: Verify wheel installs with no build fallback
+        if: matrix.target != 'aarch64' && matrix.target != 'armv7l'
+        working-directory: "bindings/python"
+        shell: bash
+        run: |
+          uv pip install --no-build --reinstall --system --find-links dist/ pyiceberg-core
+
       - name: Upload wheels
         uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
         with: