Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
8f99d0a
test.cuda: fix broken eval
Nov 23, 2023
2ce6305
pkgs/top-level/all-packages.nix: remove self-referential top-level at…
Nov 23, 2023
8e0624f
pkgs/top-level/release-outpaths.nix: vendor from ofborg
Nov 22, 2023
f73063f
pkgs/top-level/release-outpaths.nix: adjust default path value
Nov 23, 2023
90d2150
pkgs/top-level/release-outpaths.nix: add attrNamesOnly option
Nov 23, 2023
13f65d2
pkgs/top-level/release-outpaths.nix: simplify invocation
Nov 26, 2023
2fc0916
pkgs/top-level/release-outpaths.nix: make systems parameter optional
Nov 27, 2023
13071ee
pkgs/top-level/release-outpaths.nix: add includeBroken parameter
Nov 26, 2023
b7382b3
pkgs/top-level/release.nix: add attrNamesOnly option
Nov 23, 2023
c374e98
treewide: add __attrsFailEvaluation and __recurseIntoDerivationForRel…
Nov 23, 2023
6321a13
AAAAAASomeThingsFailToEvaluate: provide a message which is actually h…
Nov 23, 2023
ea66923
pkgs/top-level/release-attrpaths-superset.nix: init
Nov 23, 2023
6ccdba4
pkgs/test/release/release-attrpaths-superset.nix: init
Nov 23, 2023
7287ec4
lib/tests/release.nix: run release-attrpaths-superset.nix
Nov 23, 2023
81f83f1
pkgs/top-level/release-attrpaths-superset.nix: add enableWarnings?tru…
Dec 1, 2023
c6b12e2
pkgs/top-level/release-attrpaths-superset.nix: exempt AAAAAASomeThing…
Dec 1, 2023
46123db
pkgs/top-level/release-attrpaths-superset.nix: pass through checkMeta
Dec 1, 2023
5637128
pkgs/top-level/release-outpaths.nix: dont short-circuit handleEvalIss…
Dec 1, 2023
2ff68ce
pkgs/top-level/release-outpaths.nix: never attempt to build unfree pa…
Dec 1, 2023
d704ab5
pkgs/top-level/release-attrpaths-superset.nix: add another weird edge…
Dec 1, 2023
f13e316
pkgs/top-level/release-outpaths-parallel.{nix,sh}: init 5x faster eva…
Nov 23, 2023
3bec976
pkgs/top-level/release-outpaths-parallel.nix: remove default for attr…
Dec 1, 2023
5963d5a
pkgs/top-level/nohydra: init
Nov 27, 2023
c4b7e89
pkgs/top-level/nohydra/instantiate.sh: dont attempt to build unfree s…
Dec 1, 2023
857dbcd
delete obsolete leftover shell script
Dec 3, 2023
a1c3535
nohydra: fix the sagetex problem
Dec 6, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions lib/tests/release.nix
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,15 @@ let
echo "Running lib/tests/systems.nix"
[[ $(nix-instantiate --eval --strict lib/tests/systems.nix | tee /dev/stderr) == '[ ]' ]];

cp -r ${../../pkgs} pkgs
cp -r ${../../default.nix} default.nix
cp -r ${../../nixos} nixos
cp -r ${../../maintainers} maintainers
cp -r ${../../.version} .version
cp -r ${../../doc} doc
echo "Running pkgs/top-level/release-attrpaths-superset.nix"
nix-instantiate --eval --strict --json pkgs/top-level/release-attrpaths-superset.nix -A names > /dev/null

mkdir $out
echo success > $out/${nix.version}
'';
Expand Down
1 change: 1 addition & 0 deletions lib/types.nix
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ let
;
outer_types =
rec {
__attrsFailEvaluation = true;
isType = type: x: (x._type or "") == type;

setType = typeName: value: value // {
Expand Down
2 changes: 1 addition & 1 deletion pkgs/applications/editors/eclipse/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,6 @@ in rec {

### Plugins

plugins = callPackage ./plugins.nix { };
plugins = callPackage ./plugins.nix { } // { __attrsFailEvaluation = true; };

}
Original file line number Diff line number Diff line change
Expand Up @@ -89,4 +89,4 @@ self: let

in elpaDevelPackages // { inherit elpaBuild; });

in generateElpa { }
in (generateElpa { }) // { __attrsFailEvaluation = true; }
Original file line number Diff line number Diff line change
Expand Up @@ -181,4 +181,4 @@ self: let

in elpaPackages // { inherit elpaBuild; });

in generateElpa { }
in (generateElpa { }) // { __attrsFailEvaluation = true; }
Original file line number Diff line number Diff line change
Expand Up @@ -113,4 +113,6 @@ in
emacsSessionManagement = self.session-management-for-emacs;
rectMark = self.rect-mark;
sunriseCommander = self.sunrise-commander;

__attrsFailEvaluation = true;
}
Original file line number Diff line number Diff line change
Expand Up @@ -728,4 +728,5 @@ let
in lib.mapAttrs (n: v: if lib.hasAttr n overrides then overrides.${n} else v) super);

in
generateMelpa { }
(generateMelpa { })
// { __attrsFailEvaluation = true; }
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ self: let
generated ? ./nongnu-generated.nix
}: let

imported = import generated {
imported = (import generated {
callPackage = pkgs: args: self.callPackage pkgs (args // {
# Use custom elpa url fetcher with fallback/uncompress
fetchurl = buildPackages.callPackage ./fetchelpa.nix { };
});
};
}) // { __attrsFailEvaluation = true; };

super = imported;

Expand Down
2 changes: 1 addition & 1 deletion pkgs/applications/editors/jetbrains/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -595,6 +595,6 @@ in
update-channel = products.webstorm.update-channel;
};

plugins = callPackage ./plugins { };
plugins = callPackage ./plugins { } // { __attrsFailEvaluation = true; };

}
3 changes: 3 additions & 0 deletions pkgs/desktops/gnome/extensions/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ let
lib.trivial.pipe extensions [
(map (extension: lib.nameValuePair extension.extensionUuid extension))
builtins.listToAttrs
(attrs: attrs // { __attrsFailEvaluation = true; })
];

# Map the list of extensions to an attrset based on the pname as key, which is more human readable than the UUID
Expand Down Expand Up @@ -66,6 +67,7 @@ in rec {

# Keep the last three versions in here
gnomeExtensions = lib.trivial.pipe (gnome43Extensions // gnome44Extensions // gnome45Extensions) [
(v: builtins.removeAttrs v [ "__attrsFailEvaluation" ])
# Apply some custom patches for automatically packaged extensions
(callPackage ./extensionOverrides.nix {})
# Add all manually packaged extensions
Expand All @@ -88,4 +90,5 @@ in rec {
# Make the set "public"
lib.recurseIntoAttrs
];

}
2 changes: 1 addition & 1 deletion pkgs/development/compilers/chicken/4/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ let
callPackage = newScope self;

self = {
pkgs = self;
pkgs = self // { recurseForDerivations = false; };

fetchegg = callPackage ./fetchegg { };

Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/rust/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ in
bootRustPlatform = makeRustPlatform bootstrapRustPackages;
in {
# Packages suitable for build-time, e.g. `build.rs`-type stuff.
buildRustPackages = (selectRustPackage buildPackages).packages.stable;
buildRustPackages = (selectRustPackage buildPackages).packages.stable // { __attrsFailEvaluation = true; };
# Analogous to stdenv
rustPlatform = makeRustPlatform self.buildRustPackages;
rustc = self.callPackage ./rustc.nix ({
Expand Down
3 changes: 2 additions & 1 deletion pkgs/development/compilers/swift/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ let
darwin = pkgs.darwin.overrideScope (_: prev: {
inherit apple_sdk;
inherit (apple_sdk) Libsystem LibsystemCross libcharset libunwind objc4 configd IOKit Security;
CF = apple_sdk.CoreFoundation;
CF = apple_sdk.CoreFoundation // { __attrsFailEvaluation = true; };
__attrsFailEvaluation = true;
});
xcodebuild = pkgs.xcbuild.override {
inherit (apple_sdk.frameworks) CoreServices CoreGraphics ImageIO;
Expand Down
3 changes: 2 additions & 1 deletion pkgs/development/haskell-modules/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ let

haskellPackages = pkgs.callPackage makePackageSet {
package-set = initialPackages;
inherit stdenv haskellLib ghc buildHaskellPackages extensible-self all-cabal-hashes;
inherit stdenv haskellLib ghc extensible-self all-cabal-hashes;
buildHaskellPackages = buildHaskellPackages // { __attrsFailEvaluation = true; };
};

platformConfigurations = lib.optionals stdenv.hostPlatform.isAarch [
Expand Down
4 changes: 2 additions & 2 deletions pkgs/development/haskell-modules/make-package-set.nix
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ in package-set { inherit pkgs lib callPackage; } self // {
Type: [str] -> drv -> drv
*/
generateOptparseApplicativeCompletions =
self.callPackage (
(self.callPackage (
{ stdenv }:

commands:
Expand All @@ -623,7 +623,7 @@ in package-set { inherit pkgs lib callPackage; } self // {
if stdenv.buildPlatform.canExecute stdenv.hostPlatform
then lib.foldr haskellLib.__generateOptparseApplicativeCompletion pkg commands
else pkg
) { };
) { }) // { __attrsFailEvaluation = true; };

/*
Modify given Haskell package to force GHC to employ the LLVM
Expand Down
3 changes: 2 additions & 1 deletion pkgs/development/interpreters/lua-5/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@ let
inherit (luaPackages) requiredLuaModules;
};
withPackages = import ./with-packages.nix { inherit buildEnv luaPackages;};
pkgs = luaPackages;
pkgs = let lp = luaPackages;
in lp // { luaPackages = lp.luaPackages // { __attrsFailEvaluation = true; }; };
interpreter = "${self}/bin/${executable}";
inherit executable luaversion;
luaOnBuild = luaOnBuildForHost.override { inherit packageOverrides; self = luaOnBuild; };
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/libraries/qt-5/5.15/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Check for any minor version changes.

let

srcs = import ./srcs.nix { inherit lib fetchgit fetchFromGitHub; };
srcs = import ./srcs.nix { inherit lib fetchgit fetchFromGitHub; } // { __attrsFailEvaluation = true; };

qtCompatVersion = srcs.qtbase.version;

Expand Down
2 changes: 2 additions & 0 deletions pkgs/test/cuda/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,6 @@ rec {
cuda-library-samples_cudatoolkit_11_2
cuda-library-samples_cudatoolkit_11_3
cuda-library-samples_cudatoolkit_11_4;

__attrsFailEvaluation = true;
}
4 changes: 2 additions & 2 deletions pkgs/test/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -123,11 +123,11 @@ with pkgs;

macOSSierraShared = callPackage ./macos-sierra-shared {};

cross = callPackage ./cross {};
cross = callPackage ./cross {} // { __attrsFailEvaluation = true; };

php = recurseIntoAttrs (callPackages ./php {});

pkg-config = recurseIntoAttrs (callPackage ../top-level/pkg-config/tests.nix { });
pkg-config = recurseIntoAttrs (callPackage ../top-level/pkg-config/tests.nix { }) // { __recurseIntoDerivationForReleaseJobs = true; };

buildRustCrate = callPackage ../build-support/rust/build-rust-crate/test { };
importCargoLock = callPackage ../build-support/rust/test/import-cargo-lock { };
Expand Down
59 changes: 59 additions & 0 deletions pkgs/test/release/release-attrpaths-superset.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
{ lib ? import ../../../lib
, pkgs ? import ../../.. { }
}:
let

nixpkgs-source = lib.cleanSource ../../..;

attrpaths-calculated-the-ofborg-way-drv =
pkgs.runCommand "attrpaths-calculated-the-ofborg-way.txt" {} ''
cp -r ${nixpkgs-source} nixpkgs
mkdir fake-store
${pkgs.nix}/bin/nix-env --store ./fake-store \
-qaP \
--no-name \
--arg checkMeta false \
--argstr path $(pwd)/nixpkgs \
-f nixpkgs/pkgs/top-level/release-outpaths.nix \
| sed 's/\.[^.]*$//' \
| sort \
| uniq \
> $out
'';

# yes, IFD
attrpaths-calculated-the-ofborg-way =
lib.splitString "\n"
(builtins.readFile
(import attrpaths-calculated-the-ofborg-way-drv)
);

attrpaths-calculated-the-fast-way =
(import ../../../pkgs/top-level/release-attrpaths-superset.nix { })
.names;

attrset-with-every-ofborg-way-attr-set-to-true =
builtins.listToAttrs
(map (path: lib.nameValuePair path true)
attrpaths-calculated-the-ofborg-way);

attrset-with-every-fast-way-attr-set-to-false =
builtins.listToAttrs
(map (path: lib.nameValuePair path false)
attrpaths-calculated-the-fast-way);

attrset-should-have-no-true-attrvalues =
attrset-with-every-ofborg-way-attr-set-to-true
// attrset-with-every-fast-way-attr-set-to-false;

failures =
lib.filter
(v: v != null)
(lib.mapAttrsToList
(k: v: if v == true then k else null)
attrset-should-have-no-true-attrvalues);

in {
# should be []
inherit failures;
}
Loading