]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
require nox 2025.10.16, remove python version workaround
authorMike Bayer <mike_mp@zzzcomputing.com>
Sat, 18 Oct 2025 20:05:14 +0000 (16:05 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 21 Oct 2025 18:06:08 +0000 (14:06 -0400)
the workaround for [1] no longer works now that the fix has
been committed.  slightly surprising but just require that version
of nox and carry on

[1] https://github.com/wntrblm/nox/pull/999

Change-Id: I4b4031c3d3d02399f55f9750237de61e5e90d179
(cherry picked from commit e1f3b43ad8b45afca3a7a363a41103f5f468f461)

noxfile.py
tools/toxnox.py

index 16ba3023a54ec8e8688e4e87e5c9e5f41ec3c6b8..3b60941b16bc1a9d138766186d2a1f01b12cbf57 100644 (file)
@@ -10,6 +10,9 @@ from typing import Set
 
 import nox
 
+nox.needs_version = ">=2025.10.16"
+
+
 if True:
     sys.path.insert(0, ".")
     from tools.toxnox import extract_opts
@@ -68,8 +71,8 @@ def _setup_for_driver(
 ) -> None:
 
     # install driver deps listed out in pyproject.toml
-    nogreenlet_deps = f"tests-{basename.replace("_", "-")}"
-    greenlet_deps = f"tests-{basename.replace("_", "-")}-asyncio"
+    nogreenlet_deps = f"tests-{basename.replace('_', '-')}"
+    greenlet_deps = f"tests-{basename.replace('_', '-')}-asyncio"
 
     deps = nox.project.dependency_groups(
         pyproject,
index 897abfc77403fe96d646a03188619d0ffaf3950e..891fc70f9c42c4d1ee31c513681c58540c7147e7 100644 (file)
@@ -74,27 +74,6 @@ def tox_parameters(
     def _is_py_version(token: str) -> bool:
         return bool(PY_RE.match(token))
 
-    def _expand_python_version(token: str) -> str:
-        """expand pyx.y(t) tags into executable names.
-
-        Works around nox issue fixed at
-        https://github.com/wntrblm/nox/pull/999 by providing full executable
-        name
-
-        """
-        if sys.platform == "win32":
-            return token
-
-        m = PY_RE.match(token)
-
-        # do this matching minimally so that it only happens for the
-        # free-threaded versions.  on windows, the "pythonx.y" syntax doesn't
-        # work due to the use of the "py" tool
-        if m and m.group(2) == "t":
-            return f"python{m.group(1)}"
-        else:
-            return token
-
     def _python_to_tag(token: str) -> str:
         m = PY_RE.match(token)
         if m:
@@ -186,9 +165,7 @@ def tox_parameters(
                 )
 
     params = [
-        nox.param(
-            *[_expand_python_version(a) for a in args], tags=tags, id=ids
-        )
+        nox.param(*args, tags=tags, id=ids)
         for args, tags, ids in _recur_param([], [], token_lists)
         if filter_ is None or filter_(**dict(zip(names, args)))
     ]