diff --git a/nixos/lib/test-driver/default.nix b/nixos/lib/test-driver/default.nix index 26652db6016e61..a47825c73b33b1 100644 --- a/nixos/lib/test-driver/default.nix +++ b/nixos/lib/test-driver/default.nix @@ -7,7 +7,6 @@ , netpbm , qemu_test , socat -, ruff , tesseract4 , vde2 , extraPythonPackages ? (_ : []) diff --git a/nixos/modules/image/repart-image.nix b/nixos/modules/image/repart-image.nix index cc4c2211e3d303..40197e7aff0dca 100644 --- a/nixos/modules/image/repart-image.nix +++ b/nixos/modules/image/repart-image.nix @@ -6,7 +6,6 @@ , runCommand , python3 , black -, ruff , mypy , systemd , fakeroot @@ -62,7 +61,7 @@ let amendRepartDefinitions = runCommand "amend-repart-definitions.py" { # TODO: ruff does not splice properly in nativeBuildInputs - depsBuildBuild = [ ruff ]; + depsBuildBuild = [ python3.pkgs.ruff ]; nativeBuildInputs = [ python3 black mypy ]; } '' install ${./amend-repart-definitions.py} $out diff --git a/pkgs/by-name/mu/music-assistant/update-providers.py b/pkgs/by-name/mu/music-assistant/update-providers.py index cb2683120b14d8..cf2688e408c6ec 100755 --- a/pkgs/by-name/mu/music-assistant/update-providers.py +++ b/pkgs/by-name/mu/music-assistant/update-providers.py @@ -1,5 +1,5 @@ #!/usr/bin/env nix-shell -#!nix-shell -i python3 -p "python3.withPackages (ps: with ps; [ jinja2 mashumaro orjson aiofiles packaging ])" -p pyright ruff isort +#!nix-shell -i python3 -p "python3.withPackages (ps: with ps; [ jinja2 mashumaro orjson aiofiles packaging ruff ])" -p pyright isort import asyncio import json import os.path diff --git a/pkgs/by-name/nb/nbqa/package.nix b/pkgs/by-name/nb/nbqa/package.nix index 07fdcdde271a74..2def39a080ff85 100644 --- a/pkgs/by-name/nb/nbqa/package.nix +++ b/pkgs/by-name/nb/nbqa/package.nix @@ -3,9 +3,6 @@ python3, fetchFromGitHub, - # optional-dependencies - ruff, - # tests versionCheckHook, }: @@ -27,8 +24,9 @@ let setuptools ]; - optional-dependencies.toolchain = - (with python3.pkgs; [ + optional-dependencies.toolchain = ( + with python3.pkgs; + [ black blacken-docs flake8 @@ -37,10 +35,9 @@ let mypy pylint pyupgrade - ]) - ++ [ ruff - ]; + ] + ); dependencies = with python3.pkgs; [ autopep8 diff --git a/pkgs/by-name/op/openapi-python-client/package.nix b/pkgs/by-name/op/openapi-python-client/package.nix index a4445a6a567049..f412a1d24587d3 100644 --- a/pkgs/by-name/op/openapi-python-client/package.nix +++ b/pkgs/by-name/op/openapi-python-client/package.nix @@ -5,7 +5,6 @@ python3Packages, fetchFromGitHub, installShellFiles, - ruff, testers, openapi-python-client, }: @@ -35,8 +34,9 @@ python3Packages.buildPythonApplication rec { hatchling ]; - dependencies = - (with python3Packages; [ + dependencies = ( + with python3Packages; + [ attrs httpx jinja2 @@ -46,8 +46,9 @@ python3Packages.buildPythonApplication rec { shellingham typer typing-extensions - ]) - ++ [ ruff ]; + ruff + ] + ); # ruff is not packaged as a python module in nixpkgs pythonRemoveDeps = [ "ruff" ]; diff --git a/pkgs/by-name/ru/ruff-lsp/package.nix b/pkgs/by-name/ru/ruff-lsp/package.nix index b2a3a9285a72d5..8b31700fed0e6d 100644 --- a/pkgs/by-name/ru/ruff-lsp/package.nix +++ b/pkgs/by-name/ru/ruff-lsp/package.nix @@ -3,9 +3,6 @@ python3Packages, fetchFromGitHub, - # nativeCheckInputs - ruff, - # tests versionCheckHook, @@ -50,7 +47,7 @@ python3Packages.buildPythonApplication rec { makeWrapperArgs = [ # prefer ruff from user's PATH, that's usually desired behavior - "--suffix PATH : ${lib.makeBinPath [ ruff ]}" + "--suffix PATH : ${lib.makeBinPath [ python3Packages.ruff ]}" # Unset ambient PYTHONPATH in the wrapper, so ruff-lsp only ever runs with # its own, isolated set of dependencies. This works because the correct diff --git a/pkgs/servers/home-assistant/update-component-packages.py b/pkgs/servers/home-assistant/update-component-packages.py index 1c68331d1c1c32..65215196a25d45 100755 --- a/pkgs/servers/home-assistant/update-component-packages.py +++ b/pkgs/servers/home-assistant/update-component-packages.py @@ -1,5 +1,5 @@ #! /usr/bin/env nix-shell -#! nix-shell -i python3 -p "python3.withPackages (ps: with ps; [ packaging rich ])" -p pyright ruff isort +#! nix-shell -i python3 -p "python3.withPackages (ps: with ps; [ packaging rich ruff ])" -p pyright isort # # This script downloads Home Assistant's source tarball. # Inside the homeassistant/components directory, each integration has an associated manifest.json, diff --git a/pkgs/servers/home-assistant/update.py b/pkgs/servers/home-assistant/update.py index 70eb77ce9a1cd9..aee1affa87de7d 100755 --- a/pkgs/servers/home-assistant/update.py +++ b/pkgs/servers/home-assistant/update.py @@ -1,5 +1,5 @@ #!/usr/bin/env nix-shell -#!nix-shell -I nixpkgs=channel:nixpkgs-unstable -i python3 -p "python3.withPackages (ps: with ps; [ aiohttp packaging ])" -p git nurl pyright ruff isort +#!nix-shell -I nixpkgs=channel:nixpkgs-unstable -i python3 -p "python3.withPackages (ps: with ps; [ aiohttp packaging ruff ])" -p git nurl pyright isort import asyncio import json