-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #20 from TheTechromancer/multiple-python-versions
Test Multiple Python Versions (+3.13 Support)
- Loading branch information
Showing
3 changed files
with
27 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,7 @@ on: | |
branches: | ||
- main | ||
tags: | ||
- '*' | ||
- "*" | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
|
@@ -31,11 +31,12 @@ jobs: | |
target: x86_64 | ||
#- runner: self-hosted-arm64 | ||
# target: aarch64 | ||
python-version: ["3.8", "3.13"] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.8' | ||
python-version: ${{ matrix.python-version }} | ||
|
||
# On linux we don't use graalvm/[email protected] action to install graalvm because it will install it | ||
# on the runner machine and on linux the build will happen inside a manylinux docker. | ||
|
@@ -46,8 +47,8 @@ jobs: | |
with: | ||
command: build | ||
#working-directory: "bindings/extractous-python" # dont use working dir with docker fails to reapply permission on target dir | ||
args: --manifest-path bindings/extractous-python/Cargo.toml --release --out bindings/extractous-python/dist -i python3.8 --compatibility manylinux_2_28 | ||
sccache: 'false' | ||
args: --manifest-path bindings/extractous-python/Cargo.toml --release --out bindings/extractous-python/dist -i python${{ matrix.python-version }} --compatibility manylinux_2_28 | ||
sccache: "false" | ||
target: ${{ matrix.platform.target }} | ||
container: quay.io/pypa/manylinux_2_28_${{ matrix.platform.target }}:latest | ||
before-script-linux: .github/workflows/install-graalvm-sdkman.sh 23.0.1-graalce | ||
|
@@ -56,6 +57,7 @@ jobs: | |
|
||
# On linux we don't need to patch the wheel as the RPATH is set by the rustc compiler | ||
- name: Upload wheels | ||
if: ${{ matrix.python-version == '3.8' }} | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: wheels-linux-${{ matrix.platform.target }} | ||
|
@@ -92,7 +94,6 @@ jobs: | |
cd bindings/extractous-python | ||
pytest -s | ||
windows: | ||
runs-on: ${{ matrix.platform.runner }} | ||
strategy: | ||
|
@@ -104,20 +105,20 @@ jobs: | |
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.8' | ||
python-version: "3.8" | ||
architecture: ${{ matrix.platform.target }} | ||
- uses: graalvm/[email protected] | ||
with: | ||
java-version: '23' | ||
distribution: 'graalvm-community' | ||
set-java-home: 'true' | ||
java-version: "23" | ||
distribution: "graalvm-community" | ||
set-java-home: "true" | ||
- name: Build wheels | ||
uses: PyO3/maturin-action@v1 | ||
with: | ||
target: ${{ matrix.platform.target }} | ||
working-directory: "bindings/extractous-python" | ||
args: --release --out dist --find-interpreter | ||
sccache: 'true' | ||
sccache: "true" | ||
- name: Upload wheels | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
|
@@ -146,25 +147,25 @@ jobs: | |
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.8' | ||
python-version: "3.8" | ||
|
||
# - uses: graalvm/[email protected] | ||
# with: | ||
# java-version: '23' | ||
# distribution: 'liberica' | ||
# set-java-home: 'true' | ||
# - name: Install graalvm | ||
# run: | | ||
# set -e | ||
# bash .github/workflows/install-graalvm-sdkman-macos.sh 24.1.1.r23-nik | ||
# - uses: graalvm/[email protected] | ||
# with: | ||
# java-version: '23' | ||
# distribution: 'liberica' | ||
# set-java-home: 'true' | ||
# - name: Install graalvm | ||
# run: | | ||
# set -e | ||
# bash .github/workflows/install-graalvm-sdkman-macos.sh 24.1.1.r23-nik | ||
|
||
- name: Build wheels | ||
uses: PyO3/maturin-action@v1 | ||
with: | ||
target: ${{ matrix.platform.target }} | ||
working-directory: "bindings/extractous-python" | ||
args: --release --out dist --find-interpreter | ||
sccache: 'true' | ||
sccache: "true" | ||
|
||
- name: Patch wheel lib | ||
run: | | ||
|
@@ -218,7 +219,7 @@ jobs: | |
url: https://pypi.org/p/extractous | ||
permissions: | ||
contents: read | ||
id-token: write # IMPORTANT: mandatory for trusted publishing | ||
id-token: write # IMPORTANT: mandatory for trusted publishing | ||
steps: | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
|
@@ -242,7 +243,7 @@ jobs: | |
name: pypi | ||
url: https://pypi.org/p/extractous | ||
permissions: | ||
id-token: write # IMPORTANT: mandatory for trusted publishing | ||
id-token: write # IMPORTANT: mandatory for trusted publishing | ||
steps: | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters