top-level/aliases: Remove unneeded dontDistribute
It is not necessary now that we no longer evaluate aliases on Hydra. It was introduced to prevent Hydra from using aliases as an entry point to recurse into attribute sets that are not recursible in all-packages.nix: https://github.com/NixOS/nixpkgs/commit/2d0a7c4eeecd22f26eb37f6077a0397c32250375 This removes four levels from the stack trace when trying to evaluate a removed alias that throws. Ideally, we would also remove the `removeRecurseForDerivations` but that is probably still needed for `nix-env`: https://github.com/NixOS/nixpkgs/commit/c10f7050c56ddbfb500ef5a73367f810438a8416 https://github.com/NixOS/nixpkgs/commit/0b67f7cb5dfc2b5080b8e3046917a0a15bb5140d
This commit is contained in:
@@ -27,13 +27,6 @@ let
|
||||
then removeAttrs alias [ "recurseForDerivations" ]
|
||||
else alias;
|
||||
|
||||
# Disabling distribution prevents top-level aliases for non-recursed package
|
||||
# sets from building on Hydra.
|
||||
removeDistribute = alias: with lib;
|
||||
if isDerivation alias then
|
||||
dontDistribute alias
|
||||
else alias;
|
||||
|
||||
# Make sure that we are not shadowing something from all-packages.nix.
|
||||
checkInPkgs = n: alias:
|
||||
if builtins.hasAttr n super
|
||||
@@ -43,9 +36,8 @@ let
|
||||
mapAliases = aliases:
|
||||
lib.mapAttrs
|
||||
(n: alias:
|
||||
removeDistribute
|
||||
(removeRecurseForDerivations
|
||||
(checkInPkgs n alias)))
|
||||
removeRecurseForDerivations
|
||||
(checkInPkgs n alias))
|
||||
aliases;
|
||||
in
|
||||
|
||||
|
||||
Reference in New Issue
Block a user