Add mypyc 3.13 wheel build (#4449)

This commit is contained in:
Shantanu 2024-10-07 07:32:53 -07:00 committed by GitHub
parent b7d0e7212b
commit a22b1ebbfd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 9 additions and 9 deletions

View File

@ -47,9 +47,10 @@ jobs:
include: ${{ steps.set-matrix.outputs.include }} include: ${{ steps.set-matrix.outputs.include }}
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
# Keep cibuildwheel version in sync with below
- name: Install cibuildwheel and pypyp - name: Install cibuildwheel and pypyp
run: | run: |
pipx install cibuildwheel==2.20.0 pipx install cibuildwheel==2.21.2
pipx install pypyp==1 pipx install pypyp==1
- name: generate matrix - name: generate matrix
if: github.event_name != 'pull_request' if: github.event_name != 'pull_request'
@ -74,7 +75,7 @@ jobs:
| pyp 'json.dumps({"only": x, "os": "ubuntu-latest"})' | pyp 'json.dumps({"only": x, "os": "ubuntu-latest"})'
} | pyp 'json.dumps(list(map(json.loads, lines)))' > /tmp/matrix } | pyp 'json.dumps(list(map(json.loads, lines)))' > /tmp/matrix
env: env:
CIBW_BUILD: "cp39-* cp312-*" CIBW_BUILD: "cp39-* cp313-*"
CIBW_ARCHS_LINUX: x86_64 CIBW_ARCHS_LINUX: x86_64
- id: set-matrix - id: set-matrix
run: echo "include=$(cat /tmp/matrix)" | tee -a $GITHUB_OUTPUT run: echo "include=$(cat /tmp/matrix)" | tee -a $GITHUB_OUTPUT
@ -90,7 +91,8 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- uses: pypa/cibuildwheel@v2.20.0 # Keep cibuildwheel version in sync with above
- uses: pypa/cibuildwheel@v2.21.2
with: with:
only: ${{ matrix.only }} only: ${{ matrix.only }}

View File

@ -6,10 +6,8 @@
<!-- Include any especially major or disruptive changes here --> <!-- Include any especially major or disruptive changes here -->
- Black is now officially tested with Python 3.13. Note that Black does not yet provide - Black is now officially tested with Python 3.13 and provides Python 3.13
mypyc-compiled wheels for Python 3.13, so performance may be slower than on other mypyc-compiled wheels. (#4436) (#4449)
versions of Python. We will provide 3.13 mypyc-compiled wheels in a future release.
(#4436)
- Black will issue an error when used with Python 3.12.5, due to an upstream memory - Black will issue an error when used with Python 3.12.5, due to an upstream memory
safety issue in Python 3.12.5 that can cause Black's AST safety checks to fail. Please safety issue in Python 3.12.5 that can cause Black's AST safety checks to fail. Please
use Python 3.12.6 or Python 3.12.4 instead. (#4447) use Python 3.12.6 or Python 3.12.4 instead. (#4447)

View File

@ -125,7 +125,7 @@ macos-max-compat = true
enable-by-default = false enable-by-default = false
dependencies = [ dependencies = [
"hatch-mypyc>=0.16.0", "hatch-mypyc>=0.16.0",
"mypy==1.11.2", "mypy @ git+https://github.com/python/mypy@bc8119150e49895f7a496ae7ae7362a2828e7e9e",
"click>=8.1.7", "click>=8.1.7",
] ]
require-runtime-dependencies = true require-runtime-dependencies = true
@ -192,7 +192,7 @@ build-frontend = { name = "build", args = ["--no-isolation"] }
# Note we don't have a good test for this sed horror, so if you futz with it # Note we don't have a good test for this sed horror, so if you futz with it
# make sure to test manually # make sure to test manually
before-build = [ before-build = [
"python -m pip install 'hatchling==1.20.0' hatch-vcs hatch-fancy-pypi-readme 'hatch-mypyc>=0.16.0' 'mypy==1.11.2' 'click>=8.1.7'", "python -m pip install 'hatchling==1.20.0' hatch-vcs hatch-fancy-pypi-readme 'hatch-mypyc>=0.16.0' 'mypy @ git+https://github.com/python/mypy@bc8119150e49895f7a496ae7ae7362a2828e7e9e' 'click>=8.1.7'",
"""sed -i '' -e "600,700s/'10_16'/os.environ['MACOSX_DEPLOYMENT_TARGET'].replace('.', '_')/" $(python -c 'import hatchling.builders.wheel as h; print(h.__file__)') """, """sed -i '' -e "600,700s/'10_16'/os.environ['MACOSX_DEPLOYMENT_TARGET'].replace('.', '_')/" $(python -c 'import hatchling.builders.wheel as h; print(h.__file__)') """,
] ]