Skip to content

Commit

Permalink
Merge pull request #139 from edgarrmondragon/cp313
Browse files Browse the repository at this point in the history
Support Python 3.13
  • Loading branch information
dvarrazzo authored Nov 17, 2024
2 parents 52dd8dc + ee176c4 commit 39159bf
Show file tree
Hide file tree
Showing 6 changed files with 111 additions and 43 deletions.
69 changes: 46 additions & 23 deletions .github/workflows/packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,18 @@ jobs:

build-sdist:
name: Build sdist package
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Build sdist
run: python setup.py sdist

- name: Upload artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: sdist
path: ./dist/*


Expand All @@ -26,15 +27,15 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, windows-latest, macos-latest]
pyver: [cp37, cp38, cp39, cp310, cp311, cp312]
os: [ubuntu-24.04, windows-latest, macos-latest]
pyver: [cp38, cp39, cp310, cp311, cp312, cp313]

steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Build wheels
uses: pypa/cibuildwheel@v2.16.1
uses: pypa/cibuildwheel@v2.21.2
env:
CIBW_BUILD: ${{matrix.pyver}}-*
CIBW_ARCHS_LINUX: auto
Expand All @@ -53,37 +54,39 @@ jobs:
pp*-macosx_*
- name: Upload artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: wheel-${{ matrix.pyver }}-${{ matrix.os }}
path: ./wheelhouse/*.whl


build-cross-wheel:
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
pyver: [cp37, cp38, cp39, cp310, cp311, cp312]
pyver: [cp38, cp39, cp310, cp311, cp312, cp313]
arch: [aarch64, ppc64le]

steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up QEMU for multi-arch build
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3

- name: Build wheels
uses: pypa/cibuildwheel@v2.16.1
uses: pypa/cibuildwheel@v2.21.2
env:
CIBW_BUILD: ${{matrix.pyver}}-*
CIBW_ARCHS: ${{matrix.arch}}

# Tests mostly fail because of some confusion with the python interpreter

- name: Upload artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: wheel-${{ matrix.pyver }}-${{ matrix.arch }}
path: ./wheelhouse/*.whl


Expand All @@ -92,16 +95,17 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, windows-latest, macos-latest]
os: [ubuntu-24.04, windows-latest, macos-latest]

steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Build wheels
uses: pypa/cibuildwheel@v2.16.1
uses: pypa/cibuildwheel@v2.21.2
env:
CIBW_BUILD: pp*
CIBW_SKIP: pp37-*
CIBW_TEST_EXTRAS: test
CIBW_TEST_COMMAND: pytest --color=yes -m 'not embedded' {project}/tests
# Passing a space in a param is a b*tch on windows.
Expand All @@ -115,31 +119,50 @@ jobs:
pp*-macosx_*
- name: Upload artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: wheels-pp-${{ matrix.os }}
path: ./wheelhouse/*.whl


build-cross-wheel-pypy:
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
strategy:
fail-fast: false

steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up QEMU for multi-arch build
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3

- name: Build wheels
uses: pypa/cibuildwheel@v2.16.1
uses: pypa/cibuildwheel@v2.21.2
env:
CIBW_BUILD: pp*
CIBW_SKIP: pp37-*

# Tests mostly fail because of some confusion with the python interpreter

- name: Upload artifacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: wheels-pp-cross
path: ./wheelhouse/*.whl


merge:
runs-on: ubuntu-latest
needs:
- build-sdist
- build-wheel
- build-cross-wheel
- build-wheel-pypy
- build-cross-wheel-pypy
steps:
- name: Merge Artifacts
uses: actions/upload-artifact/merge@v4
with:
name: setproctitle-artifacts
delete-merged: true
56 changes: 44 additions & 12 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,32 @@ on:
jobs:

linux-tests:
runs-on: ubuntu-20.04
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "pypy-3.8"]
python-version:
- "3.8"
- "3.9"
- "3.10"
- "3.11"
- "3.12"
- "3.13"
- "pypy-3.8"
- "pypy-3.9"
- "pypy-3.10"
os:
- ubuntu-24.04

steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{matrix.python-version}}
allow-prereleases: true
architecture: x64

- name: Install Tox
Expand All @@ -39,17 +51,24 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [3.7, 3.8, 3.9, "3.10", "3.11", "3.12"]
python-version:
- 3.8
- 3.9
- "3.10"
- "3.11"
- "3.12"
- "3.13"
architecture: ['x64', 'x86']

steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up Python ${{matrix.python-version}}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{matrix.python-version}}
allow-prereleases: true
architecture: ${{matrix.architecture}}

- name: Install Tox
Expand All @@ -60,20 +79,33 @@ jobs:


macos-tests:
runs-on: macos-latest
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
python-version: [3.7, 3.8, 3.9, "3.10", "3.11", "3.12"]
python-version:
- "3.11"
- "3.12"
- "3.13"
os:
- macos-latest
include:
- python-version: 3.8
os: macos-13
- python-version: 3.9
os: macos-13
- python-version: "3.10"
os: macos-13

steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up Python ${{matrix.python-version}}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{matrix.python-version}}
allow-prereleases: true

- name: Install Tox
run: pip install tox
Expand All @@ -87,7 +119,7 @@ jobs:

steps:
- name: Checkout repos
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install Tox
run: xcrun python3 -m pip install tox
Expand Down
9 changes: 8 additions & 1 deletion HISTORY.rst
Original file line number Diff line number Diff line change
@@ -1,10 +1,17 @@
Releases history
----------------

Version 1.3.4
-------------

- Add support for Python 3.13 (issue #139).
- Drop support for Python 3.7.


Version 1.3.3
-------------

- Add support for Python 3.12
- Add support for Python 3.12.
- Fix package metadata to include Python 3.11, 3.12.


Expand Down
2 changes: 1 addition & 1 deletion pkg/setproctitle/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

logger = logging.getLogger("setproctitle")

__version__ = "1.3.3"
__version__ = "1.3.4"

__all__ = [
"setproctitle",
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,12 @@
License :: OSI Approved :: BSD License
Programming Language :: C
Programming Language :: Python :: 3
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Programming Language :: Python :: 3.11
Programming Language :: Python :: 3.12
Programming Language :: Python :: 3.13
Operating System :: POSIX :: Linux
Operating System :: POSIX :: BSD
Operating System :: MacOS :: MacOS X
Expand Down Expand Up @@ -118,7 +118,7 @@ def do_build(with_extension):
download_url="http://pypi.python.org/pypi/setproctitle/",
license="BSD-3-Clause",
platforms=["GNU/Linux", "BSD", "MacOS X", "Windows"],
python_requires=">=3.7",
python_requires=">=3.8",
classifiers=classifiers,
packages=["setproctitle"],
package_dir={"setproctitle": "pkg/setproctitle"},
Expand Down
14 changes: 10 additions & 4 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
[tox]
envlist = 3.7, 3.8, 3.9, 3.10, 3.11, 3.12, pypy-3.8
envlist = 3.8, 3.9, 3.10, 3.11, 3.12, 3.13, pypy-3.8, pypy-3.9, pypy-3.10

[testenv]
commands =
pytest {posargs}
extras =
test

[testenv:3.7]
basepython = python3.7

[testenv:3.8]
basepython = python3.8

Expand All @@ -25,8 +22,17 @@ basepython = python3.11
[testenv:3.12]
basepython = python3.12

[testenv:3.13]
basepython = python3.13

[testenv:pypy-3.8]
basepython = pypy3.8

[testenv:pypy-3.9]
basepython = pypy3.9

[testenv:pypy-3.10]
basepython = pypy3.10

[testenv:xcode]
basepython = {env:XCODE_PYTHON}

0 comments on commit 39159bf

Please sign in to comment.