From aff72c9958e14607be7d0c51a6a0878638f7cdec Mon Sep 17 00:00:00 2001 From: mawl Date: Tue, 19 Sep 2023 11:28:44 +0200 Subject: [PATCH] feat: Add Python 3.11 to list of available Python versions Currently Python 3.11 isn't in the list of available Python versions. This commit extends the list of versions and sets 3.11 as default version. + Update versions of Python tools: * Python 3.10.8 to 3.11.4 * Pyenv v2.3.7 to v2.3.27 to have Python 3.11.4 environment available * Poetry 1.2.2 to 1.6.1 to fix https://github.com/oss-review-toolkit/ort/issues/7333 Signed-off-by: mawl --- Dockerfile | 6 +++--- plugins/package-managers/python/src/main/kotlin/Pip.kt | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index b021c4a055a00..8d13850c633c8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -126,8 +126,8 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \ tk-dev \ && sudo rm -rf /var/lib/apt/lists/* -ARG PYTHON_VERSION=3.10.8 -ARG PYENV_GIT_TAG=v2.3.7 +ARG PYTHON_VERSION=3.11.4 +ARG PYENV_GIT_TAG=v2.3.27 ENV PYENV_ROOT=/opt/python ENV PATH=$PATH:$PYENV_ROOT/shims:$PYENV_ROOT/bin @@ -138,7 +138,7 @@ RUN curl -kSs https://pyenv.run | bash \ ARG CONAN_VERSION=1.57.0 ARG PYTHON_INSPECTOR_VERSION=0.9.8 ARG PYTHON_PIPENV_VERSION=2022.9.24 -ARG PYTHON_POETRY_VERSION=1.2.2 +ARG PYTHON_POETRY_VERSION=1.6.1 ARG PIPTOOL_VERSION=22.2.2 ARG SCANCODE_VERSION=32.0.6 diff --git a/plugins/package-managers/python/src/main/kotlin/Pip.kt b/plugins/package-managers/python/src/main/kotlin/Pip.kt index 18b45fb8d1120..f01bc7bff4acb 100644 --- a/plugins/package-managers/python/src/main/kotlin/Pip.kt +++ b/plugins/package-managers/python/src/main/kotlin/Pip.kt @@ -39,8 +39,8 @@ import org.ossreviewtoolkit.utils.ort.showStackTrace private const val OPTION_OPERATING_SYSTEM_DEFAULT = "linux" private val OPERATING_SYSTEMS = listOf(OPTION_OPERATING_SYSTEM_DEFAULT, "macos", "windows") -private const val OPTION_PYTHON_VERSION_DEFAULT = "3.10" -private val PYTHON_VERSIONS = listOf("2.7", "3.6", "3.7", "3.8", "3.9", OPTION_PYTHON_VERSION_DEFAULT) +private const val OPTION_PYTHON_VERSION_DEFAULT = "3.11" +private val PYTHON_VERSIONS = listOf("2.7", "3.6", "3.7", "3.8", "3.9", "3.10", OPTION_PYTHON_VERSION_DEFAULT) /** * The [PIP](https://pip.pypa.io/) package manager for Python. Also see