-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
fix: improve support for Python 3.11-dev #3368
Merged
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
267cf87
ci: support Python 3.11-dev
henryiii 497439d
fix: use PyFrame_GetCode on Python 3.9+
henryiii 719ce97
ci: some bitiness of pypy not supported on win
henryiii 4ce3725
chore: update CMake support to 3.22rc1 to quiet warning
henryiii 0925f0e
fix: use dev version of py to fix Py 3.11
henryiii b517ab8
tests: print proper Eigen version
henryiii 4a1f3b2
ci: include pypy2, not sure why
henryiii 4c5c4cc
ci: avoid running on Python 3.11 for now
henryiii abe454f
ci: fix runs
henryiii 4866433
ci: simpler PyPy usage, drop unmaintained scipy + pypy index
henryiii b04f4cd
ci: only binary numpy, wait on pypy 3.8
henryiii 7f1fa8c
refactor: address review
henryiii File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,6 +13,9 @@ concurrency: | |
group: test-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
env: | ||
PIP_ONLY_BINARY: numpy | ||
|
||
jobs: | ||
# This is the "main" test suite, which tests a large number of different | ||
# versions of default compilers and Python versions in GitHub Actions. | ||
|
@@ -22,13 +25,14 @@ jobs: | |
matrix: | ||
runs-on: [ubuntu-latest, windows-latest, macos-latest] | ||
python: | ||
- 2.7 | ||
- 3.5 | ||
- 3.6 | ||
- 3.9 | ||
- 3.10-dev | ||
- pypy2 | ||
- pypy3 | ||
- '2.7' | ||
- '3.5' | ||
- '3.6' | ||
- '3.9' | ||
- '3.10' | ||
# - '3.11-dev' | ||
- 'pypy-3.7-v7.3.5' | ||
# - 'pypy-3.8' | ||
|
||
# Items in here will either be added to the build matrix (if not | ||
# present), or add new keys to an existing matrix element if all the | ||
|
@@ -46,18 +50,8 @@ jobs: | |
python: 3.6 | ||
args: > | ||
-DPYBIND11_FINDPYTHON=ON | ||
|
||
# These items will be removed from the build matrix, keys must match. | ||
exclude: | ||
# Currently 32bit only, and we build 64bit | ||
- runs-on: windows-latest | ||
python: pypy2 | ||
- runs-on: windows-latest | ||
python: pypy3 | ||
|
||
# TODO: PyPy2 7.3.3 segfaults, while 7.3.2 was fine. | ||
- runs-on: ubuntu-latest | ||
python: pypy2 | ||
- runs-on: macos-latest | ||
python: pypy-2.7 | ||
|
||
name: "🐍 ${{ matrix.python }} • ${{ matrix.runs-on }} • x64 ${{ matrix.args }}" | ||
runs-on: ${{ matrix.runs-on }} | ||
|
@@ -93,7 +87,8 @@ jobs: | |
key: ${{ runner.os }}-pip-${{ matrix.python }}-x64-${{ hashFiles('tests/requirements.txt') }} | ||
|
||
- name: Prepare env | ||
run: python -m pip install -r tests/requirements.txt --prefer-binary | ||
run: | | ||
python -m pip install -r tests/requirements.txt | ||
|
||
- name: Setup annotations on Linux | ||
if: runner.os == 'Linux' | ||
|
@@ -117,7 +112,7 @@ jobs: | |
|
||
- name: C++11 tests | ||
# TODO: Figure out how to load the DLL on Python 3.8+ | ||
if: "!(runner.os == 'Windows' && (matrix.python == 3.8 || matrix.python == 3.9 || matrix.python == '3.10-dev'))" | ||
if: "!(runner.os == 'Windows' && (matrix.python == 3.8 || matrix.python == 3.9 || matrix.python == '3.10' || matrix.python == '3.11-dev' || matrix.python == 'pypy-3.8'))" | ||
run: cmake --build . --target cpptest -j 2 | ||
|
||
- name: Interface test C++11 | ||
|
@@ -145,7 +140,7 @@ jobs: | |
|
||
- name: C++ tests | ||
# TODO: Figure out how to load the DLL on Python 3.8+ | ||
if: "!(runner.os == 'Windows' && (matrix.python == 3.8 || matrix.python == 3.9 || matrix.python == '3.10-dev'))" | ||
if: "!(runner.os == 'Windows' && (matrix.python == 3.8 || matrix.python == 3.9 || matrix.python == '3.10' || matrix.python == '3.11-dev' || matrix.python == 'pypy-3.8'))" | ||
run: cmake --build build2 --target cpptest | ||
|
||
# Third build - C++17 mode with unstable ABI | ||
|
@@ -196,11 +191,12 @@ jobs: | |
fail-fast: false | ||
matrix: | ||
include: | ||
- python-version: 3.9 | ||
# TODO: Fails on 3.10, investigate | ||
- python-version: "3.9" | ||
python-debug: true | ||
valgrind: true | ||
- python-version: 3.10-dev | ||
python-debug: false | ||
# - python-version: "3.11-dev" | ||
# python-debug: false | ||
|
||
name: "🐍 ${{ matrix.python-version }}${{ matrix.python-debug && '-dbg' || '' }} (deadsnakes)${{ matrix.valgrind && ' • Valgrind' || '' }} • x64" | ||
runs-on: ubuntu-latest | ||
|
@@ -244,7 +240,8 @@ jobs: | |
sudo apt-get install libc6-dbg # Needed by Valgrind | ||
|
||
- name: Prepare env | ||
run: python -m pip install -r tests/requirements.txt --prefer-binary | ||
run: | | ||
python -m pip install -r tests/requirements.txt | ||
|
||
- name: Configure | ||
run: > | ||
|
@@ -521,7 +518,7 @@ jobs: | |
- name: Install dependencies | ||
run: | | ||
set +e; source /opt/intel/oneapi/setvars.sh; set -e | ||
python3 -m pip install -r tests/requirements.txt --prefer-binary | ||
python3 -m pip install -r tests/requirements.txt | ||
|
||
- name: Configure C++11 | ||
run: | | ||
|
@@ -612,7 +609,8 @@ jobs: | |
run: python3 -m pip install --upgrade pip | ||
|
||
- name: Install dependencies | ||
run: python3 -m pip install cmake -r tests/requirements.txt --prefer-binary | ||
run: | | ||
python3 -m pip install cmake -r tests/requirements.txt | ||
|
||
- name: VAR_BUILD_TYPE 7 | ||
if: matrix.centos == 7 | ||
|
@@ -739,8 +737,7 @@ jobs: | |
- 3.7 | ||
- 3.8 | ||
- 3.9 | ||
- pypy3 | ||
# TODO: fix hang on pypy2 | ||
- pypy-3.6 | ||
|
||
include: | ||
- python: 3.9 | ||
|
@@ -769,7 +766,8 @@ jobs: | |
arch: x86 | ||
|
||
- name: Prepare env | ||
run: python -m pip install -r tests/requirements.txt --prefer-binary | ||
run: | | ||
python -m pip install -r tests/requirements.txt | ||
|
||
# First build - C++11 mode and inplace | ||
- name: Configure ${{ matrix.args }} | ||
|
@@ -815,7 +813,8 @@ jobs: | |
toolset: 14.0 | ||
|
||
- name: Prepare env | ||
run: python -m pip install -r tests/requirements.txt --prefer-binary | ||
run: | | ||
python -m pip install -r tests/requirements.txt | ||
|
||
# First build - C++11 mode and inplace | ||
- name: Configure | ||
|
@@ -864,7 +863,8 @@ jobs: | |
uses: jwlawson/[email protected] | ||
|
||
- name: Prepare env | ||
run: python -m pip install -r tests/requirements.txt --prefer-binary | ||
run: | | ||
python -m pip install -r tests/requirements.txt | ||
|
||
# First build - C++11 mode and inplace | ||
- name: Configure | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
--extra-index-url https://antocuni.github.io/pypy-wheels/manylinux2010/ | ||
numpy==1.16.6; python_version<"3.6" and sys_platform!="win32" | ||
numpy==1.18.0; platform_python_implementation=="PyPy" and sys_platform=="darwin" and python_version>="3.6" | ||
numpy==1.19.3; (platform_python_implementation!="PyPy" or sys_platform=="linux") and python_version=="3.6" | ||
numpy==1.21.2; (platform_python_implementation!="PyPy" or sys_platform=="linux") and python_version>="3.7" and python_version<"3.10" | ||
numpy==1.21.2; platform_python_implementation!="PyPy" and sys_platform=="linux" and python_version=="3.10" | ||
numpy==1.16.6; python_version<"3.6" and sys_platform!="win32" and platform_python_implementation!="PyPy" | ||
numpy==1.19.0; platform_python_implementation=="PyPy" and sys_platform=="linux" and python_version=="3.6" | ||
numpy==1.20.0; platform_python_implementation=="PyPy" and sys_platform=="linux" and python_version=="3.7" | ||
numpy==1.19.3; platform_python_implementation!="PyPy" and python_version=="3.6" | ||
numpy==1.21.3; platform_python_implementation!="PyPy" and python_version>="3.7" | ||
py @ git+https://github.com/pytest-dev/py; python_version>="3.11" | ||
pytest==4.6.9; python_version<"3.5" | ||
pytest==6.1.2; python_version=="3.5" | ||
pytest==6.2.4; python_version>="3.6" | ||
pytest-timeout | ||
scipy==1.2.3; (platform_python_implementation!="PyPy" or sys_platform=="linux") and python_version<"3.6" | ||
scipy==1.5.4; (platform_python_implementation!="PyPy" or sys_platform=="linux") and python_version>="3.6" and python_version<"3.10" | ||
scipy==1.2.3; platform_python_implementation!="PyPy" and python_version<"3.6" | ||
scipy==1.5.4; platform_python_implementation!="PyPy" and python_version>="3.6" and python_version<"3.10" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a really long and complex block of code. It might be nice to move to a separate function somewhere under detail.
This PR is very large already, we could do that separately.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, can be done separately later.