From bbd92b3542d500362759f20fe72749800b54a010 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Tue, 14 Aug 2018 17:33:36 +0200 Subject: [PATCH] disallow deprecated callPackage api --- lib/evalRepo.nix | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/evalRepo.nix b/lib/evalRepo.nix index b7383c249..a021114d0 100644 --- a/lib/evalRepo.nix +++ b/lib/evalRepo.nix @@ -27,8 +27,7 @@ let # True if not all arguments are either passed by default (e.g. pkgs) or defaulted (e.g. foo ? 10) usesCallPackage = ! lib.all (arg: lib.elem arg (lib.attrNames passedArgs) || args.${arg}) (lib.attrNames args); -in if usesCallPackage then lib.warn '' +in if usesCallPackage then throw '' NUR repository ${prettyName} is using the deprecated callPackage syntax which might result in infinite recursion when used with NixOS modules. - '' (passedArgs.pkgs.callPackages src {}) - else expr (builtins.intersectAttrs args passedArgs) + '' else expr (builtins.intersectAttrs args passedArgs)