I edit from times to times python files in nixpkgs (vim updater, lately the docker stream builder script etc). The experience is a bit frustrating because nixpkgs enforces flake8 rules (the build fails if lines are too long for instance https://github.com/NixOS/nixpkgs/issues/269811) but nixpkgs lacks the configuration files for these tools, which would help pass the checks.
For instance flake8 limit line length at 80. the vim update.py recommends to use black (a python formatter) which by default doesn't care about line length or with a default different than 80.
Could we add a flake8 / black configuration to help edit python files in a way that conforms to nixpkgs' check ?
Apparently black can be configured by pyproject.toml in a [tool.black] section.
Note that line length is not something supported by editorconfig.
Technical details
Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.
Issue description
I edit from times to times python files in nixpkgs (vim updater, lately the docker stream builder script etc). The experience is a bit frustrating because nixpkgs enforces flake8 rules (the build fails if lines are too long for instance https://github.com/NixOS/nixpkgs/issues/269811) but nixpkgs lacks the configuration files for these tools, which would help pass the checks.
For instance flake8 limit line length at 80. the vim update.py recommends to use black (a python formatter) which by default doesn't care about line length or with a default different than 80. Could we add a flake8 / black configuration to help edit python files in a way that conforms to nixpkgs' check ?
Apparently black can be configured by pyproject.toml in a
[tool.black]
section. Note that line length is not something supported by editorconfig.Technical details
Please run
nix-shell -p nix-info --run "nix-info -m"
and paste the result.