Skip to content

Upload 3.13 & free-threaded nightly wheels #59136

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 21 commits into from
Jul 22, 2024
Merged
Changes from 1 commit
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
4371054
Upload free-threaded nightly wheels on Linux and macOS
lysnikolaou Jun 28, 2024
2cb8bbc
Consolidate jobs into one
lysnikolaou Jul 2, 2024
5f54ed7
Install build dependencies in before-build and pass --no-build-isolation
lysnikolaou Jul 10, 2024
8bee350
Fix {project} placeholder in cibuildwheel config
lysnikolaou Jul 10, 2024
0a842b2
Correctly quote echo CIBW_BUILD_FRONTEND command
lysnikolaou Jul 10, 2024
c2bbdcb
Run echo -e
lysnikolaou Jul 10, 2024
7e87966
Add {package} to before-build
lysnikolaou Jul 10, 2024
c36d905
Include cibw script in sdist & add matrix value for build frontend
lysnikolaou Jul 11, 2024
f11120d
Change manifest and gitattributes
lysnikolaou Jul 11, 2024
0b70025
Change gitattributes
lysnikolaou Jul 11, 2024
812527e
Install verioneer in before-build
lysnikolaou Jul 11, 2024
e46055a
Add cibw_before_test to install nightly NumPy
lysnikolaou Jul 11, 2024
c487998
Expand before-test to musl
lysnikolaou Jul 11, 2024
2258d64
Better comments plus always run before-build/before-test on 3.13
lysnikolaou Jul 11, 2024
0c4753a
Add --no-build-isolation in 3.13 as well
lysnikolaou Jul 11, 2024
15d0c8d
Install nightly numpy before windows tests
lysnikolaou Jul 11, 2024
0cf5c89
Merge branch 'main' into free-threaded-wheels
lysnikolaou Jul 16, 2024
edcbf3c
Merge branch 'main' into free-threaded-wheels
lysnikolaou Jul 19, 2024
2397f4c
Address feedback; add todo for NumPy nightly and move default outside…
lysnikolaou Jul 19, 2024
06b6ca1
Merge branch 'main' into free-threaded-wheels
mroeschke Jul 22, 2024
778a60a
Set build_frontend to 'build' in pyodide build
lysnikolaou Jul 22, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
107 changes: 107 additions & 0 deletions .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -199,3 +199,110 @@ jobs:
source ci/upload_wheels.sh
set_upload_vars
upload_wheels

build_free_threaded_wheels:
needs: build_sdist
name: Build wheel for ${{ matrix.python }}-${{ matrix.buildplat[1] }}
if: >-
(github.event_name == 'schedule') ||
github.event_name == 'workflow_dispatch' ||
(github.event_name == 'pull_request' &&
contains(github.event.pull_request.labels.*.name, 'Build'))
runs-on: ${{ matrix.buildplat[0] }}
strategy:
fail-fast: false
matrix:
# GitHub Actions doesn't support pairing matrix values together, let's improvise
# https://github.com/github/feedback/discussions/7835#discussioncomment-1769026
buildplat:
- [ubuntu-22.04, manylinux_x86_64]
- [ubuntu-22.04, musllinux_x86_64]
- [macos-13, macosx_x86_64]
- [macos-14, macosx_arm64]
python: ["cp313t"]
env:
IS_PUSH: false
IS_SCHEDULE_DISPATCH: ${{ github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
steps:
- name: Checkout pandas
uses: actions/checkout@v4
with:
fetch-depth: 0

# TODO: Build wheels from sdist again
# There's some sort of weird race condition?
# within Github that makes the sdist be missing files

# We need to build wheels from the sdist since the sdist
# removes unnecessary files from the release
- name: Download sdist (not macOS)
#if: ${{ matrix.buildplat[1] != 'macosx_*' }}
uses: actions/download-artifact@v4
with:
name: sdist
path: ./dist

- name: Output sdist name (macOS)
id: save-path
shell: bash -el {0}
run: echo "sdist_name=$(ls ./dist)" >> "$GITHUB_ENV"

# Python version used to build sdist doesn't matter
# wheel will be built from sdist with the correct version
- name: Unzip sdist (macOS)
if: ${{ startsWith(matrix.buildplat[1], 'macosx') }}
run: |
tar -xzf ./dist/${{ env.sdist_name }} -C ./dist

- name: Output sdist name (macOS)
id: save-path2
shell: bash -el {0}
run: echo "sdist_name=$(cd ./dist && ls -d */)" >> "$GITHUB_ENV"

- name: Build wheels
uses: pypa/[email protected]
with:
package-dir: ./dist/${{ startsWith(matrix.buildplat[1], 'macosx') && env.sdist_name || needs.build_sdist.outputs.sdist_file }}
env:
CIBW_PRERELEASE_PYTHONS: True
CIBW_FREE_THREADED_SUPPORT: True
CIBW_BUILD: ${{ matrix.python }}-${{ matrix.buildplat[1] }}

- name: Set up Python
uses: mamba-org/setup-micromamba@v1
with:
environment-name: wheel-env
# Use a fixed Python, since we might have an unreleased Python not
# yet present on conda-forge
create-args: >-
python=3.11
anaconda-client
wheel
cache-downloads: true
cache-environment: true

- name: Validate wheel RECORD
shell: bash -el {0}
run: for whl in $(ls wheelhouse); do wheel unpack wheelhouse/$whl -d /tmp; done

- uses: actions/upload-artifact@v4
with:
name: ${{ matrix.python }}-${{ matrix.buildplat[1] }}
path: ./wheelhouse/*.whl

- name: Upload wheels & sdist
if: ${{ success() && (env.IS_SCHEDULE_DISPATCH == 'true' || env.IS_PUSH == 'true') }}
shell: bash -el {0}
env:
PANDAS_STAGING_UPLOAD_TOKEN: ${{ secrets.PANDAS_STAGING_UPLOAD_TOKEN }}
PANDAS_NIGHTLY_UPLOAD_TOKEN: ${{ secrets.PANDAS_NIGHTLY_UPLOAD_TOKEN }}
# trigger an upload to
# https://anaconda.org/scientific-python-nightly-wheels/pandas
# for cron jobs or "Run workflow" (restricted to main branch).
# Tags will upload to
# https://anaconda.org/multibuild-wheels-staging/pandas
# The tokens were originally generated at anaconda.org
run: |
source ci/upload_wheels.sh
set_upload_vars
upload_wheels
Loading