From 816cfb12d1833d1ab04272dfa2cd3674a714bb0e Mon Sep 17 00:00:00 2001 From: Dmitry Shibanov Date: Mon, 11 Oct 2021 15:18:43 +0300 Subject: [PATCH] add possible fixes for python 3.11.0-alpha.1 --- tests/python-tests.ps1 | 2 +- tests/sources/python-modules.py | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/python-tests.ps1 b/tests/python-tests.ps1 index aa7ac3a..969f315 100644 --- a/tests/python-tests.ps1 +++ b/tests/python-tests.ps1 @@ -24,7 +24,7 @@ function Analyze-MissingModules([string] $buildOutputLocation) { $module = $regexMatch.Groups[1].Value.Trim() Write-Host "Failed missing modules:" Write-Host $module - if ( ($module -eq "_tkinter") -and ( ($Version -like "3.10.0-beta*") -or ($Version -like "3.10.0-alpha*") ) ) { + if ( ($module -eq "_tkinter") -and ( [semver]"$($Version.Major).$($Version.Minor)" -ge [semver]"3.10" -and $Version.PreReleaseLabel ) ) { Write-Host "$module $Version ignored" } else { return 1 diff --git a/tests/sources/python-modules.py b/tests/sources/python-modules.py index abb033f..e2d094c 100644 --- a/tests/sources/python-modules.py +++ b/tests/sources/python-modules.py @@ -261,6 +261,10 @@ if sys.version_info >= (3, 10): standard_library.remove('symbol') standard_library.remove('formatter') +# 'binhex' module has been removed from Python 3.11 +if sys.version_info >= (3, 11): + standard_library.remove('binhex') + # Remove tkinter and Easter eggs excluded_modules = [ 'antigravity',