Skip to content
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

build: support Python 3.11 #45191

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build-tarball.yml
Expand Up @@ -28,7 +28,7 @@ concurrency:
cancel-in-progress: true

env:
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
FLAKY_TESTS: keep_retrying

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-windows.yml
Expand Up @@ -23,7 +23,7 @@ concurrency:
cancel-in-progress: true

env:
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
FLAKY_TESTS: keep_retrying

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/coverage-linux.yml
Expand Up @@ -26,7 +26,7 @@ concurrency:
cancel-in-progress: true

env:
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
FLAKY_TESTS: keep_retrying

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/coverage-windows.yml
Expand Up @@ -28,7 +28,7 @@ concurrency:
cancel-in-progress: true

env:
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
FLAKY_TESTS: keep_retrying

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linters.yml
Expand Up @@ -14,7 +14,7 @@ concurrency:
cancel-in-progress: true

env:
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
NODE_VERSION: lts/*

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-asan.yml
Expand Up @@ -30,7 +30,7 @@ concurrency:

env:
ASAN_OPTIONS: intercept_tls_get_addr=0
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
FLAKY_TESTS: keep_retrying

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-internet.yml
Expand Up @@ -21,7 +21,7 @@ concurrency:
cancel-in-progress: true

env:
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
FLAKY_TESTS: keep_retrying

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-linux.yml
Expand Up @@ -23,7 +23,7 @@ concurrency:
cancel-in-progress: true

env:
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
FLAKY_TESTS: keep_retrying

permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-macos.yml
Expand Up @@ -29,7 +29,7 @@ concurrency:
cancel-in-progress: true

env:
PYTHON_VERSION: '3.10'
PYTHON_VERSION: '3.11'
FLAKY_TESTS: keep_retrying

permissions:
Expand Down
6 changes: 3 additions & 3 deletions BUILDING.md
Expand Up @@ -225,7 +225,7 @@ The Node.js project supports Python >= 3 for building and testing.

* `gcc` and `g++` >= 8.3 or newer
* GNU Make 3.81 or newer
* Python 3.6, 3.7, 3.8, 3.9, or 3.10 (see note above)
* Python >=3.6 <=3.11 (see note above)
* For test coverage, your Python installation must include pip.

Installation via Linux package manager can be achieved with:
Expand All @@ -241,7 +241,7 @@ FreeBSD and OpenBSD users may also need to install `libexecinfo`.
#### macOS prerequisites

* Xcode Command Line Tools >= 11 for macOS
* Python 3.6, 3.7, 3.8, 3.9, or 3.10 (see note above)
* Python >=3.6 <=3.11 (see note above)
* For test coverage, your Python installation must include pip.

macOS users can install the `Xcode Command Line Tools` by running
Expand Down Expand Up @@ -565,7 +565,7 @@ to run it again before invoking `make -j4`.

##### Option 1: Manual install

* [Python 3.10](https://www.microsoft.com/en-us/p/python-310/9pjpw5ldxlz5)
* [Python 3.11](https://apps.microsoft.com/store/detail/python-311/9NRWMJP3717K)
* The "Desktop development with C++" workload from
[Visual Studio 2019](https://visualstudio.microsoft.com/vs/older-downloads/#visual-studio-2019-and-other-products) or
the "C++ build tools" workload from the
Expand Down
3 changes: 2 additions & 1 deletion configure
Expand Up @@ -4,6 +4,7 @@
# Note that the mix of single and double quotes is intentional,
# as is the fact that the ] goes on a new line.
_=[ 'exec' '/bin/sh' '-c' '''
command -v python3.11 >/dev/null && exec python3.11 "$0" "$@"
command -v python3.10 >/dev/null && exec python3.10 "$0" "$@"
command -v python3.9 >/dev/null && exec python3.9 "$0" "$@"
command -v python3.8 >/dev/null && exec python3.8 "$0" "$@"
Expand All @@ -22,7 +23,7 @@ except ImportError:
from distutils.spawn import find_executable as which

print('Node.js configure: Found Python {}.{}.{}...'.format(*sys.version_info))
acceptable_pythons = ((3, 10), (3, 9), (3, 8), (3, 7), (3, 6))
acceptable_pythons = ((3, 11), (3, 10), (3, 9), (3, 8), (3, 7), (3, 6))
if sys.version_info[:2] in acceptable_pythons:
import configure
else:
Expand Down