Mic92 / nixpkgs-review

Review pull-requests on https://github.com/NixOS/nixpkgs
MIT License
350 stars 59 forks source link

summary is hidden behind lots of collisions #370

Open teto opened 8 months ago

teto commented 8 months ago

I often run nixpkgs-review on vimPlugins update or the lua package update set, at the moment https://github.com/NixOS/nixpkgs/pull/258819 .

In both cases, the summary is followed by a long list of collisions that makes the summary a pain to find:

warning: collision between `/nix/store/82icynaidvzyic2g349cqi4p9a5d4aa2-vimplugin-ai.vim-2023-10-03/doc/tags' and `/nix/store/qc4bdwi6zhk4r1vzbcxrnwrrjnm33a6g-vimplugin-CheckAttach-2019-05-08/doc/tags'
warning: collision between `/nix/store/82icynaidvzyic2g349cqi4p9a5d4aa2-vimplugin-ai.vim-2023-10-03/.gitignore' and `/nix/store/7k2xjb9fd6x0k2myb04759cd6sl0w9pc-vimplugin-ChatGPT.nvim-2023-10-16/.gitignore'
warning: collision between `/nix/store/82icynaidvzyic2g349cqi4p9a5d4aa2-vimplugin-ai.vim-2023-10-03/README.md' and `/nix/store/hsshj9pwkm5di7vha04haas87hfxya8b-vimplugin-BetterLua.vim-2020-08-14/README.md'
warning: collision between `/nix/store/82icynaidvzyic2g349cqi4p9a5d4aa2-vimplugin-ai.vim-2023-10-03/LICENSE.txt' and `/nix/store/kxbsb0yhk9z70dxr73jmyzwm4sfw8aa0-vimplugin-LanguageClient-neovim-0.1.161/LICENSE.txt'

I haven't looked at the code but the log shows that nixpkgs-review creates a big environment that contains everything. Would it make sense to ignore collisions in that environment ? why is the env needed ?

Mic92 commented 8 months ago

The buildEnv is needed because otherwise your stack will overflow from all the environment variables set (resulting in not being able to run any command). It is only used for large rebuilds and we also already ignore collisions, it's just a warning being printed.