-
Notifications
You must be signed in to change notification settings - Fork 250
Open
Description
https://github.com/bglgwyng/haskell.nix-playground/blob/main/cabal.project
Here is the configuration. And I'm trying to build 'foobarbaz' package from my local Hackage server.
The repo is not a complete reproducer, but if it is required, then I'll also share it.
The build failed with the following message.
error: build of '/nix/store/6bgydlyq32nmfmp78hnv6raxkjkis1n9-haskell-project-plan-to-nix-pkgs.drv' on 'ssh://[email protected]' failed: builder for '/nix/store/6bgydlyq32nmfmp78hnv6raxkjkis1n9-haskell-project-plan-to-nix-pkgs.drv' failed with exit code 1;
last 10 log lines:
> Warning: The package list for 'hackage.haskell.org' is 20321 days old.
> Run 'cabal update' to get the latest list of available packages.
> Warning: The package list for 'head.hackage.ghc.haskell.org' is 20321 days
> old.
> Run 'cabal update' to get the latest list of available packages.
> Warning: The package list for 'localhost' is 20321 days old.
> Run 'cabal update' to get the latest list of available packages.
> Resolving dependencies...
> Downloading foobarbaz-0.1.0.3
> /nix/store/xx2kir20xyfcmgn2jy04q8h2d7bnx03i-dot-cabal/packages/localhost/foobarbaz: createDirectory: permission denied (Permission denied)
For full logs, run 'nix log /nix/store/6bgydlyq32nmfmp78hnv6raxkjkis1n9-haskell-project-plan-to-nix-pkgs.drv'.
error:
… while evaluating the attribute 'packages'
at /nix/store/ds92gdw8wy93yl02bd5axzbyckp91djj-source/flake.nix:33:9:
32|
33| packages = flake.packages // { default = flake.packages."hello:exe:hello"; };
| ^
34| });
… in the left operand of the update (//) operator
at /nix/store/ds92gdw8wy93yl02bd5axzbyckp91djj-source/flake.nix:33:35:
32|
33| packages = flake.packages // { default = flake.packages."hello:exe:hello"; };
| ^
34| });
… while evaluating the attribute 'packages'
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/lib/default.nix:406:7:
405| inherit name;
406| value =
| ^
407| # This favours the first item (`a`) in the case of duplicates
… in the left operand of the update (//) operator
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/lib/default.nix:413:29:
412| else
413| (b.${name} or {}) // (a.${name} or {});
| ^
414| }) (__attrNames (a // b)));
… while evaluating the attribute 'packages'
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/lib/default.nix:546:11:
545| # `nix build .#pkg-name:test:test-name`
546| packages
| ^
547| # Used by:
… from call site
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/lib/default.nix:531:22:
530| , haskellPackages ? selectPackages project.hsPkgs
531| , packages ? mkFlakePackages haskellPackages
| ^
532| , apps ? mkFlakeApps haskellPackages
… while calling 'foldrAttrVals'
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/lib/default.nix:37:25:
36|
37| foldrAttrVals = f: z: attrs:
| ^
38| lib.foldr f z (builtins.attrValues attrs);
… from call site
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/lib/default.nix:38:5:
37| foldrAttrVals = f: z: attrs:
38| lib.foldr f z (builtins.attrValues attrs);
| ^
39|
… while calling 'foldr'
at /nix/store/dzwwydggypqg4p8r6if5zdaqyzhsxjkd-source/lib/lists.nix:139:14:
138| foldr =
139| op: nul: list:
| ^
140| let
… from call site
at /nix/store/dzwwydggypqg4p8r6if5zdaqyzhsxjkd-source/lib/lists.nix:144:5:
143| in
144| fold' 0;
| ^
145|
… while calling 'fold''
at /nix/store/dzwwydggypqg4p8r6if5zdaqyzhsxjkd-source/lib/lists.nix:142:15:
141| len = length list;
142| fold' = n: if n == len then nul else op (elemAt list n) (fold' (n + 1));
| ^
143| in
… while evaluating a branch condition
at /nix/store/dzwwydggypqg4p8r6if5zdaqyzhsxjkd-source/lib/lists.nix:142:18:
141| len = length list;
142| fold' = n: if n == len then nul else op (elemAt list n) (fold' (n + 1));
| ^
143| in
… while calling the 'length' builtin
at /nix/store/dzwwydggypqg4p8r6if5zdaqyzhsxjkd-source/lib/lists.nix:141:13:
140| let
141| len = length list;
| ^
142| fold' = n: if n == len then nul else op (elemAt list n) (fold' (n + 1));
… while calling the 'attrValues' builtin
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/lib/default.nix:38:20:
37| foldrAttrVals = f: z: attrs:
38| lib.foldr f z (builtins.attrValues attrs);
| ^
39|
… from call site
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/lib/default.nix:530:29:
529| selectPackages ? haskellLib.selectProjectPackages
530| , haskellPackages ? selectPackages project.hsPkgs
| ^
531| , packages ? mkFlakePackages haskellPackages
… while calling 'filterAttrs'
at /nix/store/dzwwydggypqg4p8r6if5zdaqyzhsxjkd-source/lib/attrsets.nix:657:23:
656| */
657| filterAttrs = pred: set: removeAttrs set (filter (name: !pred name set.${name}) (attrNames set));
| ^
658|
… while calling the 'removeAttrs' builtin
at /nix/store/dzwwydggypqg4p8r6if5zdaqyzhsxjkd-source/lib/attrsets.nix:657:28:
656| */
657| filterAttrs = pred: set: removeAttrs set (filter (name: !pred name set.${name}) (attrNames set));
| ^
658|
… while evaluating the attribute 'hsPkgs'
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/overlays/haskell.nix:739:15:
738| # Haskell packages
739| hsPkgs = final.lib.mapAttrs (packageName: package':
| ^
740| if package' == null
… while calling the 'mapAttrs' builtin
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/overlays/haskell.nix:739:24:
738| # Haskell packages
739| hsPkgs = final.lib.mapAttrs (packageName: package':
| ^
740| if package' == null
… while calling the 'removeAttrs' builtin
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/overlays/haskell.nix:773:20:
772| }
773| ) (builtins.removeAttrs rawProject.hsPkgs
| ^
774| # These are functions not packages
… while evaluating the attribute 'hsPkgs'
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/overlays/haskell.nix:707:44:
706| project = addProjectAndPackageAttrs rec {
707| inherit (pkg-set.config) hsPkgs;
| ^
708| inherit pkg-set;
… while evaluating a branch condition
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/overlays/haskell.nix:676:25:
675| else project;
676| pkg-set = if plan-pkgs ? configurationError
| ^
677| then {
… while evaluating a branch condition
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/overlays/haskell.nix:661:27:
660| callProjectResults = callCabalProjectToNix config;
661| plan-pkgs = if !builtins.pathExists (callProjectResults.projectNix + "/plan.json")
| ^
662| then
… in the argument of the not operator
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/overlays/haskell.nix:661:31:
660| callProjectResults = callCabalProjectToNix config;
661| plan-pkgs = if !builtins.pathExists (callProjectResults.projectNix + "/plan.json")
| ^
662| then
… while calling the 'pathExists' builtin
at /nix/store/38mczifa2z3rpsrh4gavhvijgzmr0awv-source/overlays/haskell.nix:661:31:
660| callProjectResults = callCabalProjectToNix config;
661| plan-pkgs = if !builtins.pathExists (callProjectResults.projectNix + "/plan.json")
| ^
662| then
… while realising the context of path '/nix/store/kgdzzx9553nwspcvz11d4sj2ldpqwp8y-haskell-project-plan-to-nix-pkgs/plan.json'
error: builder for '/nix/store/6bgydlyq32nmfmp78hnv6raxkjkis1n9-haskell-project-plan-to-nix-pkgs.drv' failed with exit code 1;
last 12 log lines:
> Configuration is affected by the following files:
> - cabal.project
> Warning: The package list for 'hackage.haskell.org' is 20321 days old.
> Run 'cabal update' to get the latest list of available packages.
> Warning: The package list for 'head.hackage.ghc.haskell.org' is 20321 days
> old.
> Run 'cabal update' to get the latest list of available packages.
> Warning: The package list for 'localhost' is 20321 days old.
> Run 'cabal update' to get the latest list of available packages.
> Resolving dependencies...
> Downloading foobarbaz-0.1.0.3
> /nix/store/xx2kir20xyfcmgn2jy04q8h2d7bnx03i-dot-cabal/packages/localhost/foobarbaz: createDirectory: permission denied (Permission denied)
For full logs, run:
nix log /nix/store/6bgydlyq32nmfmp78hnv6raxkjkis1n9-haskell-project-plan-to-nix-pkgs.drv
And the log of plan-to-nix-pkgs is
Configuration is affected by the following files:
- cabal.project
Warning: The package list for 'hackage.haskell.org' is 20321 days old.
Run 'cabal update' to get the latest list of available packages.
Warning: The package list for 'head.hackage.ghc.haskell.org' is 20321 days
old.
Run 'cabal update' to get the latest list of available packages.
Warning: The package list for 'localhost' is 20321 days old.
Run 'cabal update' to get the latest list of available packages.
Resolving dependencies...
Downloading foobarbaz-0.1.0.3
/nix/store/xx2kir20xyfcmgn2jy04q8h2d7bnx03i-dot-cabal/packages/localhost/foobarbaz: createDirectory: permission denied (Permission denied)
which seems to indicate that it failed the directory for building 'foobarbaz' package.
Am I doing something wrong?
Metadata
Metadata
Assignees
Labels
No labels