Skip to content

Commit

Permalink
Merge pull request #1000 from Thijss/add-support-python-311
Browse files Browse the repository at this point in the history
Add support for python 3.11
  • Loading branch information
fabratu committed Nov 9, 2022
2 parents 754263d + 05d9d8d commit b01bf79
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 21 deletions.
32 changes: 25 additions & 7 deletions .github/workflows/build_wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
CIBW_BEFORE_BUILD: pip install cython
CIBW_MANYLINUX_X86_64_IMAGE: ${{ matrix.manylinux_image }}
CIBW_ARCHS_LINUX: ${{ matrix.cibw_archs }}
CIBW_BUILD: "cp38-* cp39-* cp310-*"
CIBW_BUILD: "cp38-* cp39-* cp310-* cp311-*"
CIBW_SKIP: pp*
- uses: actions/upload-artifact@v2
with:
Expand All @@ -42,6 +42,11 @@ jobs:
with:
path: ./wheelhouse/*cp310*.whl
retention-days: ${{ env.ARTIFACT_RETENTION }}
- uses: actions/upload-artifact@v2
with:
path: ./wheelhouse/*cp311*.whl
retention-days: ${{ env.ARTIFACT_RETENTION }}


cpython-linux-aarch64:
name: 'Linux CPython (${{ matrix.cibw_archs }}, ${{ matrix.manylinux_image }})'
Expand Down Expand Up @@ -102,7 +107,7 @@ jobs:
pip install cython &&
brew install libomp ninja
CIBW_ARCHS_MACOS: ${{ matrix.cibw_archs }}
CIBW_BUILD: "cp38-* cp39-* cp310-*"
CIBW_BUILD: "cp38-* cp39-* cp310-* cp311-*"
CIBW_ENVIRONMENT: CXX='c++'
CIBW_SKIP: pp*
- uses: actions/upload-artifact@v2
Expand All @@ -117,6 +122,10 @@ jobs:
with:
path: ./wheelhouse/*cp310*.whl
retention-days: ${{ env.ARTIFACT_RETENTION }}
- uses: actions/upload-artifact@v2
with:
path: ./wheelhouse/*cp311*.whl
retention-days: ${{ env.ARTIFACT_RETENTION }}

# CROSSBUILDING ON MACOS IS CURRENTLY BROKEN BECAUSE OF OPENMP-DEPENDENCIES
# cpython-macos-arm64:
Expand All @@ -132,7 +141,7 @@ jobs:
# - uses: actions/setup-python@v2
# name: Install Python
# with:
# python-version: '3.10'
# python-version: '3.11'
# - name: Build wheels
# uses: pypa/cibuildwheel@v2.1.1
# env:
Expand All @@ -142,7 +151,7 @@ jobs:
# pip install --pre -i https://pypi.anaconda.org/scipy-wheels-nightly/simple scipy
# CIBW_ENVIRONMENT: CXX=c++ NETWORKIT_OSX_CROSSBUILD=ON
# CIBW_ARCHS_MACOS: ${{ matrix.cibw_archs }}
# CIBW_BUILD: "cp39-* cp310-*"
# CIBW_BUILD: "cp39-* cp310-* cp311-*"
# CIBW_SKIP: pp*
# - uses: actions/upload-artifact@v2
# with:
Expand All @@ -154,6 +163,11 @@ jobs:
# name: networkit-cp310-macos-${{ matrix.cibw_archs }}.whl
# path: ./wheelhouse/*cp310*.whl
# retention-days: ${{ env.ARTIFACT_RETENTION }}
# - uses: actions/upload-artifact@v2
# with:
# name: networkit-cp311-macos-${{ matrix.cibw_archs }}.whl
# path: ./wheelhouse/*cp311*.whl
# retention-days: ${{ env.ARTIFACT_RETENTION }}

cpython-windows:
name: 'Windows CPython (${{ matrix.cibw_archs }})'
Expand All @@ -176,7 +190,7 @@ jobs:
env:
CIBW_BEFORE_BUILD: pip install cython ipython
CIBW_ARCHS: "AMD64"
CIBW_BUILD: "cp38-* cp39-* cp310-*"
CIBW_BUILD: "cp38-* cp39-* cp310-* cp311-*"
CIBW_SKIP: pp*
- uses: actions/upload-artifact@v2
with:
Expand All @@ -190,6 +204,10 @@ jobs:
with:
path: ./wheelhouse/*cp310*.whl
retention-days: ${{ env.ARTIFACT_RETENTION }}
- uses: actions/upload-artifact@v2
with:
path: ./wheelhouse/*cp311*.whl
retention-days: ${{ env.ARTIFACT_RETENTION }}

source-distribution:
name: 'Source distribution'
Expand All @@ -201,7 +219,7 @@ jobs:
- uses: actions/setup-python@v2
name: Install Python
with:
python-version: '3.9'
python-version: '3.10'
- name: Create sdist source
run: |
pip install cython
Expand Down Expand Up @@ -241,7 +259,7 @@ jobs:
- uses: actions/setup-python@v2
name: Install Python
with:
python-version: '3.9'
python-version: '3.10'
- name: Upload to TestPyPI
run: |
pip install twine
Expand Down
28 changes: 14 additions & 14 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,10 +113,10 @@ jobs:
run: |
brew install libomp
brew install ninja
- name: Setup Python 3.10
- name: Setup Python 3.11
uses: actions/setup-python@v3
with:
python-version: '3.10'
python-version: '3.11.0'
- name: Checkout networkit
uses: actions/checkout@v2
with:
Expand Down Expand Up @@ -167,7 +167,7 @@ jobs:
CXX: ${{ matrix.compiler == 'clang-15' && '/usr/local/opt/llvm@15/bin/clang++' || 'g++-11' }}

linux-build-latest:
name: "Linux (gcc-11${{ startsWith(matrix.build-configuration, 'full') && ', CPython 3.10' || '' }}): ${{ matrix.build-configuration }}"
name: "Linux (gcc-11${{ startsWith(matrix.build-configuration, 'full') && ', CPython 3.11' || '' }}): ${{ matrix.build-configuration }}"
runs-on: ubuntu-20.04
env:
CC: gcc-11
Expand All @@ -181,10 +181,10 @@ jobs:
sudo add-apt-repository 'deb http://mirrors.kernel.org/ubuntu jammy main universe'
sudo apt-get update
sudo apt-get install gcc-11 g++-11 ninja-build
- name: Setup Python 3.10
- name: Setup Python 3.11.0
uses: actions/setup-python@v3
with:
python-version: '3.10'
python-version: '3.11.0'
- name: Checkout networkit
uses: actions/checkout@v2
with:
Expand Down Expand Up @@ -288,7 +288,7 @@ jobs:
shell: bash

linux-build-core-sanitizers-coverage:
name: "Linux (gcc-10, CPython 3.10): coverage"
name: "Linux (gcc-10, CPython 3.11): coverage"
runs-on: ubuntu-20.04
env:
CC: gcc-10
Expand All @@ -302,10 +302,10 @@ jobs:
run: |
sudo apt-get update
sudo apt-get install ninja-build
- name: Setup Python 3.10
- name: Setup Python 3.11.0
uses: actions/setup-python@v3
with:
python-version: '3.10'
python-version: '3.11.0'
- name: Checkout
uses: actions/checkout@v2
with:
Expand Down Expand Up @@ -357,16 +357,16 @@ jobs:
ctest -V -C Debug
windows-build-latest:
name: "Windows (msvc 14.31, CPython 3.10): ${{ matrix.build-configuration }}"
name: "Windows (msvc 14.31, CPython 3.11): ${{ matrix.build-configuration }}"
runs-on: windows-2022
strategy:
matrix:
build-configuration: ['full', 'full (native)']
steps:
- name: Setup Python 3.10
- name: Setup Python 3.11.0
uses: actions/setup-python@v3
with:
python-version: '3.10'
python-version: '3.11.0'
- name: Checkout networkit
uses: actions/checkout@v2
with:
Expand Down Expand Up @@ -404,7 +404,7 @@ jobs:
NATIVE: ${{ matrix.os == 'full (native)' }}

documentation-build:
name: "Linux (gcc-11, CPython 3.10): documentation"
name: "Linux (gcc-11, CPython 3.11): documentation"
runs-on: ubuntu-20.04
env:
CC: gcc-11
Expand All @@ -416,10 +416,10 @@ jobs:
sudo apt-get update
sudo apt-get install gcc-11 g++-11 ninja-build
sudo apt-get install doxygen pandoc
- name: Setup Python 3.10
- name: Setup Python 3.11.0
uses: actions/setup-python@v3
with:
python-version: '3.10'
python-version: '3.11.0'
- name: Checkout networkit
uses: actions/checkout@v2
with:
Expand Down

0 comments on commit b01bf79

Please sign in to comment.