From 17fe7175d32bb8158193787db66b6ce78981f777 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Est=C3=A8ve?= Date: Wed, 26 Mar 2025 16:42:39 +0100 Subject: [PATCH 1/3] DOC Fix Python min versions in advanced installation docs --- doc/developers/advanced_installation.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/developers/advanced_installation.rst b/doc/developers/advanced_installation.rst index e46fe48007473..85a452c8db270 100644 --- a/doc/developers/advanced_installation.rst +++ b/doc/developers/advanced_installation.rst @@ -58,7 +58,7 @@ feature, code or documentation improvement). If you plan on submitting a pull-request, you should clone from your fork instead. -#. Install a recent version of Python (3.9 or later at the time of writing) for +#. Install a recent version of Python (|PythonMinVersion| or later) for instance using conda-forge_. Conda-forge provides a conda-based distribution of Python and the most popular scientific libraries. @@ -78,7 +78,7 @@ feature, code or documentation improvement). conda activate sklearn-env #. **Alternative to conda:** You can use alternative installations of Python - provided they are recent enough (3.9 or higher at the time of writing). + provided they are recent enough (|PythonMinVersion| or higher at the time of writing). Here is an example of how to create a build environment for a Linux system's Python. Build dependencies are installed with `pip` in a dedicated virtualenv_ to avoid disrupting other Python programs installed on the system: @@ -134,7 +134,7 @@ Runtime dependencies Scikit-learn requires the following dependencies both at build time and at runtime: -- Python (>= 3.8), +- Python (>= |PythonMinVersion|), - NumPy (>= |NumpyMinVersion|), - SciPy (>= |ScipyMinVersion|), - Joblib (>= |JoblibMinVersion|), From 0ad594f2df4fecc35b9bde467079f968af85f5e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Est=C3=A8ve?= Date: Wed, 26 Mar 2025 17:44:05 +0100 Subject: [PATCH 2/3] easier fix --- doc/developers/advanced_installation.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/doc/developers/advanced_installation.rst b/doc/developers/advanced_installation.rst index 85a452c8db270..be69d5f2ea981 100644 --- a/doc/developers/advanced_installation.rst +++ b/doc/developers/advanced_installation.rst @@ -3,6 +3,11 @@ .. include:: ../min_dependency_substitutions.rst +.. + TODO Add |PythonMinVersion| to min_dependency_substitutions.rst one day. + Probably would need to change a bit sklearn/_min_dependencies.py since Python is not really a package ... +.. |PythonMinVersion| replace:: 3.10 + ================================================== Installing the development version of scikit-learn ================================================== From e192411e8ca20e5b97cfbdce6fc3d0bec93d3850 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Est=C3=A8ve?= Date: Thu, 27 Mar 2025 04:18:42 +0100 Subject: [PATCH 3/3] Update doc/developers/advanced_installation.rst MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Jérémie du Boisberranger --- doc/developers/advanced_installation.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/developers/advanced_installation.rst b/doc/developers/advanced_installation.rst index be69d5f2ea981..e39490d2292a5 100644 --- a/doc/developers/advanced_installation.rst +++ b/doc/developers/advanced_installation.rst @@ -83,7 +83,7 @@ feature, code or documentation improvement). conda activate sklearn-env #. **Alternative to conda:** You can use alternative installations of Python - provided they are recent enough (|PythonMinVersion| or higher at the time of writing). + provided they are recent enough (|PythonMinVersion| or higher). Here is an example of how to create a build environment for a Linux system's Python. Build dependencies are installed with `pip` in a dedicated virtualenv_ to avoid disrupting other Python programs installed on the system: