Add support for Python 3.11 (#11407)

* Add Python 3.11 to CI

* 3.11 in the install scripts

* ${{ format('{0}.0-alpha - {0}.X', matrix.python) }}

* bump chiavdf and chiabip158 for releases with 3.11 wheels

* also bump blspy and clvm-tools-rs

* drop the extra .X for the python setup version

* chia_rs==0.1.13

* Update install.sh

* pyinstaller==5.5

* less mutable defaults

* memory_profiler

* assert sqlite3.threadsafety >= 1

* create tasks for stopping services

(cherry picked from commit 3384714f2e3e0bdc8c3d3741027e9e4fb69a6002)

* psutil==5.9.4

* drop memory_profiler transitive dep since it now supports 3.11

* drop redundant pre-release python getting incantation

* watchdog==2.2.0

* black for py311
This commit is contained in:
Kyle Altendorf 2023-01-27 15:16:03 -08:00 committed by GitHub
parent 22dfc83d51
commit 523a5d4cf5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 14 additions and 6 deletions

View File

@ -44,7 +44,7 @@ jobs:
matrix: arm
- name: Intel
matrix: intel
python-version: ['3.7', '3.8', '3.9', '3.10']
python-version: ['3.7', '3.8', '3.9', '3.10', '3.11']
exclude:
- os:
matrix: macos

View File

@ -85,6 +85,14 @@ jobs:
matrix: '3.10'
exclude_from:
limited: True
- name: '3.11'
file_name: '3.11'
action: '3.11'
apt: '3.11'
install_sh: '3.11'
matrix: '3.11'
exclude_from:
limited: True
exclude:
- os:
matrix: macos

View File

@ -45,7 +45,7 @@ if ($null -eq (Get-Command py -ErrorAction SilentlyContinue))
Exit 1
}
$supportedPythonVersions = "3.10", "3.9", "3.8", "3.7"
$supportedPythonVersions = "3.11", "3.10", "3.9", "3.8", "3.7"
if ("$env:INSTALL_PYTHON_VERSION" -ne "")
{
$pythonVersion = $env:INSTALL_PYTHON_VERSION

View File

@ -146,7 +146,7 @@ OPENSSL_VERSION_INT=
find_python() {
set +e
unset BEST_VERSION
for V in 310 3.10 39 3.9 38 3.8 37 3.7 3; do
for V in 311 3.11 310 3.10 39 3.9 38 3.8 37 3.7 3; do
if command -v python$V >/dev/null; then
if [ "$BEST_VERSION" = "" ]; then
BEST_VERSION=$V
@ -284,8 +284,8 @@ if ! command -v "$INSTALL_PYTHON_PATH" >/dev/null; then
exit 1
fi
if [ "$PYTHON_MAJOR_VER" -ne "3" ] || [ "$PYTHON_MINOR_VER" -lt "7" ] || [ "$PYTHON_MINOR_VER" -ge "11" ]; then
echo "Chia requires Python version >= 3.7 and < 3.11.0" >&2
if [ "$PYTHON_MAJOR_VER" -ne "3" ] || [ "$PYTHON_MINOR_VER" -lt "7" ] || [ "$PYTHON_MINOR_VER" -ge "12" ]; then
echo "Chia requires Python version >= 3.7 and < 3.12.0" >&2
echo "Current Python version = $INSTALL_PYTHON_VERSION" >&2
# If Arch, direct to Arch Wiki
if type pacman >/dev/null 2>&1 && [ -f "/etc/arch-release" ]; then

View File

@ -8,7 +8,7 @@ local_scheme = "no-local-version"
[tool.black]
line-length = 120
target-version = ['py37', 'py38', 'py39', 'py310']
target-version = ['py37', 'py38', 'py39', 'py310', 'py311']
include = '''
^/(
[^/]*.py