From a30a5a9f6c2b848404d65e6d3b5eb89bd29b8c4e Mon Sep 17 00:00:00 2001 From: Olivier Grisel Date: Thu, 29 Oct 2026 16:35:25 +0100 Subject: [PATCH 1/2] 3.9 support drop was merged after the 3.7.0 release --- CHANGES.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 7f013581..91563a73 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -45,6 +45,8 @@ skipped when OpenBLAS uses the OpenMP threading layer, as documented. https://github.com/joblib/threadpoolctl/pull/283 +- Dropped official support for Python 3.9. + https://github.com/joblib/threadpoolctl/pull/255 3.7.0 (2026-09-15) ================== @@ -104,9 +106,6 @@ closures that can abort after ``os.fork()`` on some libffi builds. https://github.com/joblib/threadpoolctl/pull/242 -- Dropped official support for Python 3.9. - https://github.com/joblib/threadpoolctl/pull/255 - 3.6.0 (2025-03-13) ================== From 73e35ef8e147a73d8b53db9394a16b09ccda6d6e Mon Sep 17 00:00:00 2001 From: Olivier Grisel Date: Thu, 29 Oct 2026 17:16:55 +0100 Subject: [PATCH 2/2] Fix stale docstring related to limitting semantics --- threadpoolctl.py | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/threadpoolctl.py b/threadpoolctl.py index 47bc8e15..e3cf8a09 100644 --- a/threadpoolctl.py +++ b/threadpoolctl.py @@ -1213,9 +1213,11 @@ class threadpool_limits(_ThreadpoolLimiter): the supported libraries to `limit`. This function works for libraries that are already loaded in the interpreter and can be changed dynamically. - This effect is global and impacts the whole Python process. There is no thread level - isolation as these libraries do not offer thread-local APIs to configure the number - of threads to use in nested parallel calls. + This effect is thread-local whenever possible but this is not guaranteed + and actual behavior can depend on the controlled libraries. Notably, + OpenBLAS built with the "windows" or "pthreads" threading layers uses a + process-wide thread pool instead of independently controlled thread pools + per calling threads. Parameters ---------- @@ -1376,9 +1378,11 @@ def limit(self, *, limits=None, user_api=None): the supported libraries to `limits`. This function works for libraries that are already loaded in the interpreter and can be changed dynamically. - This effect is global and impacts the whole Python process. There is no thread - level isolation as these libraries do not offer thread-local APIs to configure - the number of threads to use in nested parallel calls. + This effect is thread-local whenever possible but this is not guaranteed + and actual behavior can depend on the controlled libraries. Notably, + OpenBLAS built with the "windows" or "pthreads" threading layers uses a + process-wide thread pool instead of independently controlled thread pools + per calling threads. Parameters ----------