diff --git a/pkgs/applications/terminal-emulators/terminator/default.nix b/pkgs/applications/terminal-emulators/terminator/default.nix index aedbb761a8ca..01047f26bc63 100644 --- a/pkgs/applications/terminal-emulators/terminator/default.nix +++ b/pkgs/applications/terminal-emulators/terminator/default.nix @@ -30,7 +30,6 @@ python3.pkgs.buildPythonApplication rec { gobject-introspection makeBinaryWrapper wrapGAppsHook3 - python3.pkgs.pytest-runner ]; buildInputs = [ diff --git a/pkgs/development/compilers/vyper/default.nix b/pkgs/development/compilers/vyper/default.nix index 56899b6acba4..89973eb524ee 100644 --- a/pkgs/development/compilers/vyper/default.nix +++ b/pkgs/development/compilers/vyper/default.nix @@ -7,7 +7,6 @@ , importlib-metadata , packaging , pycryptodome -, pytest-runner , pythonOlder , recommonmark , setuptools-scm @@ -41,7 +40,8 @@ buildPythonPackage rec { postPatch = '' # pythonRelaxDeps doesn't work substituteInPlace setup.py \ - --replace "setuptools_scm>=7.1.0,<8.0.0" "setuptools_scm>=7.1.0" + --replace-fail "setuptools_scm>=7.1.0,<8.0.0" "setuptools_scm>=7.1.0" \ + --replace-fail '"pytest-runner",' "" ''; nativeBuildInputs = [ @@ -49,7 +49,6 @@ buildPythonPackage rec { # ever since https://github.com/vyperlang/vyper/pull/2816 git - pytest-runner setuptools-scm ]; diff --git a/pkgs/development/python-modules/hikari/default.nix b/pkgs/development/python-modules/hikari/default.nix index 026176e7a7b8..dbc853b926aa 100644 --- a/pkgs/development/python-modules/hikari/default.nix +++ b/pkgs/development/python-modules/hikari/default.nix @@ -4,13 +4,12 @@ fetchFromGitHub, pytestCheckHook, pythonOlder, - pytest-runner, aiohttp, attrs, multidict, colorlog, pynacl, - pytest-cov, + pytest-cov-stub, pytest-randomly, pytest-asyncio, mock, @@ -52,9 +51,8 @@ buildPythonPackage rec { nativeCheckInputs = [ pytestCheckHook - pytest-runner pytest-asyncio - pytest-cov + pytest-cov-stub pytest-randomly mock ]; diff --git a/pkgs/development/python-modules/pytest-harvest/default.nix b/pkgs/development/python-modules/pytest-harvest/default.nix index 65325851b770..35e5945c1a62 100644 --- a/pkgs/development/python-modules/pytest-harvest/default.nix +++ b/pkgs/development/python-modules/pytest-harvest/default.nix @@ -3,7 +3,6 @@ buildPythonPackage, fetchFromGitHub, setuptools-scm, - pytest-runner, pytest, decopatch, makefun, @@ -34,11 +33,14 @@ buildPythonPackage rec { # we disable this file creation as it touches internet postPatch = '' echo "version = '${version}'" > pytest_harvest/_version.py + + substituteInPlace pytest_harvest/tests/test_lazy_and_harvest.py \ + --replace-fail "from distutils.version import LooseVersion" "from packaging.version import parse" \ + --replace-fail "LooseVersion" "parse" ''; nativeBuildInputs = [ setuptools-scm - pytest-runner ]; buildInputs = [ pytest ]; diff --git a/pkgs/development/python-modules/pytest-runner/default.nix b/pkgs/development/python-modules/pytest-runner/default.nix deleted file mode 100644 index 57b970fc98df..000000000000 --- a/pkgs/development/python-modules/pytest-runner/default.nix +++ /dev/null @@ -1,40 +0,0 @@ -{ - lib, - buildPythonPackage, - fetchPypi, - setuptools-scm, - pytest, -}: - -buildPythonPackage rec { - pname = "pytest-runner"; - version = "6.0.1"; - format = "pyproject"; - - src = fetchPypi { - inherit pname version; - hash = "sha256-cNRzlYWnAI83v0kzwBP9sye4h4paafy7MxbIiILw9Js="; - }; - - postPatch = '' - rm pytest.ini - ''; - - nativeBuildInputs = [ - setuptools-scm - pytest - ]; - - checkPhase = '' - py.test tests - ''; - - # Fixture not found - doCheck = false; - - meta = with lib; { - description = "Invoke py.test as distutils command with dependency resolution"; - homepage = "https://github.com/pytest-dev/pytest-runner"; - license = licenses.mit; - }; -} diff --git a/pkgs/development/python-modules/tf2onnx/default.nix b/pkgs/development/python-modules/tf2onnx/default.nix index 73c19842f103..54a837089bc8 100644 --- a/pkgs/development/python-modules/tf2onnx/default.nix +++ b/pkgs/development/python-modules/tf2onnx/default.nix @@ -2,7 +2,6 @@ lib, buildPythonPackage, fetchFromGitHub, - pytest-runner, # runtime dependencies numpy, onnx, @@ -34,9 +33,10 @@ buildPythonPackage rec { hash = "sha256-qtRzckw/KHWm3gjFwF+cPuBhGbfktjhYIwImwHn2CFk="; }; - nativeBuildInputs = [ - pytest-runner - ]; + postPatch = '' + substituteInPlace setup.py \ + --replace-fail "'pytest-runner'" "" + ''; pythonRelaxDeps = [ "flatbuffers" ]; diff --git a/pkgs/development/tools/analysis/cpplint/default.nix b/pkgs/development/tools/analysis/cpplint/default.nix index d9603ca0548d..b32e1cf4e678 100644 --- a/pkgs/development/tools/analysis/cpplint/default.nix +++ b/pkgs/development/tools/analysis/cpplint/default.nix @@ -35,7 +35,6 @@ python3Packages.buildPythonApplication rec { nativeCheckInputs = with python3Packages; [ pytest - pytest-runner ]; checkPhase = '' diff --git a/pkgs/tools/backup/duplicity/default.nix b/pkgs/tools/backup/duplicity/default.nix index 71d63a622d4d..da32f2323343 100644 --- a/pkgs/tools/backup/duplicity/default.nix +++ b/pkgs/tools/backup/duplicity/default.nix @@ -99,8 +99,7 @@ let self = python3.pkgs.buildPythonApplication rec { lockfile mock pexpect - pytest - pytest-runner + pytestCheckHook fasteners ]); diff --git a/pkgs/tools/virtualization/udocker/default.nix b/pkgs/tools/virtualization/udocker/default.nix index 8f0afedfd9cb..25ae2fe9ee33 100644 --- a/pkgs/tools/virtualization/udocker/default.nix +++ b/pkgs/tools/virtualization/udocker/default.nix @@ -17,6 +17,11 @@ python3Packages.buildPythonApplication rec { hash = "sha256-P49fkLvdCm/Eco+nD3SGM04PRQatBzq9CHlayueQetk="; }; + postPatch = '' + substituteInPlace setup.py \ + --replace-fail "'pytest-runner'," "" + ''; + # crun patchelf proot runc fakechroot # are download statistically linked during runtime buildInputs = [ @@ -28,7 +33,6 @@ python3Packages.buildPythonApplication rec { ]; nativeCheckInputs = with python3Packages; [ - pytest-runner pytestCheckHook ]; diff --git a/pkgs/top-level/python-aliases.nix b/pkgs/top-level/python-aliases.nix index f789cd32996b..3bcb357458f8 100644 --- a/pkgs/top-level/python-aliases.nix +++ b/pkgs/top-level/python-aliases.nix @@ -483,6 +483,7 @@ mapAliases ({ pytest-pep8 = pytestpep8; # added 2021-01-04 pytest-pep257 = throw "pytest-pep257 was removed, as the pep257 package was migrated into pycodestyle"; # added 2022-04-12 pytest-pythonpath = throw "pytest-pythonpath is obsolete as of pytest 7.0.0 and has been removed"; # added 2022-03-09 + pytest-runner = throw "pytest-runner has been removed as it uses deprecated features of setuptools and is deprecated by upstream"; # added 2024-09-15 pytest-sanic = throw "pytest-sanic has been removed because it is unmaintained and broken"; # added 2023-06-22 pytestpep8 = throw "pytestpep8 was removed because it is abandoned and no longer compatible with pytest v6.0"; # added 2020-12-10 pytestquickcheck = pytest-quickcheck; # added 2021-07-20 diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 5d2ecf9b584f..1014eaf703ac 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -12474,8 +12474,6 @@ self: super: with self; { pytest-responses = callPackage ../development/python-modules/pytest-responses { }; - pytest-runner = callPackage ../development/python-modules/pytest-runner { }; - pytest-server-fixtures = callPackage ../development/python-modules/pytest-server-fixtures { }; pytest-services = callPackage ../development/python-modules/pytest-services { };