Skip to content

Commit

Permalink
- update meta/config template to publish Windows wheels to PyPI
Browse files Browse the repository at this point in the history
  • Loading branch information
dataflake committed May 24, 2024
1 parent a522866 commit 4a680bb
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 21 deletions.
1 change: 1 addition & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ source =
[report]
show_missing = true
precision = 2
ignore_errors = True
exclude_lines =
except ImportError:
if __name__ == '__main__':
Expand Down
22 changes: 11 additions & 11 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -162,14 +162,14 @@ jobs:
if: matrix.python-version == '3.13'
run: |
pip install -U pip
pip install -U setuptools wheel twine
pip install -U "setuptools<69" wheel twine
# Remove this hack once 'cffi' has a release supporting Python 3.13.
pip install -e "git+https://github.com/python-cffi/cffi.git#egg=cffi"
- name: Install Build Dependencies
if: matrix.python-version != '3.13'
run: |
pip install -U pip
pip install -U setuptools wheel twine
pip install -U "setuptools<69" wheel twine
pip install cffi
- name: Build persistent (macOS x86_64, Python 3.8+)
Expand Down Expand Up @@ -254,14 +254,14 @@ jobs:
with:
name: persistent-${{ runner.os }}-${{ matrix.python-version }}.whl
path: dist/*whl
- name: Publish package to PyPI (mac)
# We cannot 'uses: pypa/gh-action-pypi-publish@v1.4.1' because
# that's apparently a container action, and those don't run on
# the Mac.
- name: Publish package to PyPI (Non-Linux)
# We cannot use pypa/gh-action-pypi-publish because that
# is a container action, and those don't run on macOS
# or Windows GHA runners.
if: >
github.event_name == 'push'
&& startsWith(github.ref, 'refs/tags')
&& startsWith(runner.os, 'Mac')
&& !startsWith(runner.os, 'Linux')
&& !startsWith(matrix.python-version, 'pypy')
&& !startsWith(matrix.python-version, '3.13')
env:
Expand Down Expand Up @@ -346,7 +346,7 @@ jobs:
- name: Install persistent 3.13 ${{ matrix.python-version }}
if: matrix.python-version == '3.13'
run: |
pip install -U wheel setuptools
pip install -U wheel "setuptools<69"
# Remove this hack once 'cffi' has a release supporting Python 3.13.
pip install -e "git+https://github.com/python-cffi/cffi.git#egg=cffi"
# coverage might have a wheel on PyPI for a future python version which is
Expand All @@ -362,7 +362,7 @@ jobs:
- name: Install persistent
if: matrix.python-version != '3.13'
run: |
pip install -U wheel setuptools
pip install -U wheel "setuptools<69"
pip install -U coverage
pip install -U 'cffi; platform_python_implementation == "CPython"'
# Unzip into src/ so that testrunner can find the .so files
Expand Down Expand Up @@ -634,5 +634,5 @@ jobs:
with:
user: __token__
password: ${{ secrets.TWINE_PASSWORD }}
skip_existing: true
packages_dir: wheelhouse/
skip-existing: true
packages-dir: wheelhouse/
16 changes: 8 additions & 8 deletions .manylinux-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@ tox_env_map() {
# Compile wheels
for PYBIN in /opt/python/*/bin; do
if \
[[ "${PYBIN}" == *"cp313"* ]] || \
[[ "${PYBIN}" == *"cp311"* ]] || \
[[ "${PYBIN}" == *"cp312"* ]] || \
[[ "${PYBIN}" == *"cp37"* ]] || \
[[ "${PYBIN}" == *"cp38"* ]] || \
[[ "${PYBIN}" == *"cp39"* ]] || \
[[ "${PYBIN}" == *"cp310"* ]] ; then
if [[ "${PYBIN}" == *"cp313"* ]] ; then
[[ "${PYBIN}" == *"cp313/"* ]] || \
[[ "${PYBIN}" == *"cp311/"* ]] || \
[[ "${PYBIN}" == *"cp312/"* ]] || \
[[ "${PYBIN}" == *"cp37/"* ]] || \
[[ "${PYBIN}" == *"cp38/"* ]] || \
[[ "${PYBIN}" == *"cp39/"* ]] || \
[[ "${PYBIN}" == *"cp310/"* ]] ; then
if [[ "${PYBIN}" == *"cp313/"* ]] ; then
"${PYBIN}/pip" install --pre -e /io/
"${PYBIN}/pip" wheel /io/ --pre -w wheelhouse/
else
Expand Down
4 changes: 2 additions & 2 deletions .meta.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
# https://github.com/zopefoundation/meta/tree/master/config/c-code
[meta]
template = "c-code"
commit-id = "5a4d3a13"
commit-id = "4dc0484e"

[python]
with-appveyor = true
with-appveyor = false
with-windows = true
with-pypy = true
with-future-python = true
Expand Down
1 change: 1 addition & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ envlist =
usedevelop = true
pip_pre = py313: true
deps =
setuptools < 69
py37: urllib3 < 2
Sphinx
setenv =
Expand Down

0 comments on commit 4a680bb

Please sign in to comment.