Skip to content

Error: cannot coerce a set to a stringย #21

Open
@pcboy

Description

I'm trying to run nix run nixpkgs#nixci on my flake, but I'm encountering this error from devour-flake.

๐Ÿ .
๐Ÿš nix --extra-experimental-features 'nix-command flakes' eval '.#nixci.default' --json๏ธ
๐ŸŽ default.<root>
๐Ÿš nix --extra-experimental-features 'nix-command flakes' flake lock --no-update-lock-file .๏ธ
๐Ÿš nix --extra-experimental-features 'nix-command flakes' build '/nix/store/p8vfkmfh43yy8lmz1r65dr9yq3ql7cd7-source#default' -L --no-link --print-out-paths --override-input flake . --refresh -j auto๏ธ
error:
       โ€ฆ while calling the 'derivationStrict' builtin

         at /derivation-internal.nix:9:12:

            8|
            9|   strict = derivationStrict drvAttrs;
             |            ^
           10|

       โ€ฆ while evaluating derivation 'devour-output'
         whose name attribute is located at /nix/store/qjqzr7905xxv3rv70z7mkpp06lalnzzb-source/pkgs/stdenv/generic/make-derivation.nix:300:7

       โ€ฆ while evaluating attribute 'text' of derivation 'devour-output'

         at /nix/store/qjqzr7905xxv3rv70z7mkpp06lalnzzb-source/pkgs/build-support/trivial-builders/default.nix:148:16:

          147|     runCommand name
          148|       { inherit text executable checkPhase allowSubstitutes preferLocalBuild;
             |                ^
          149|         passAsFile = [ "text" ];

       error: cannot coerce a set to a string
Error: devour-flake failed to run (exited: 1)

It seems it's happening because one of my outputs is actually of the form:

      packages.pythonPkgs = {
        package1 = pkgs.callPackage ./packages/mypackage1/. {};
        package2 = pkgs.callPackage ./packages/mypackage2/. {};
      };

Is there a way to make that structure work with nixci/devour-output? I'm would like to clearly separate python packages in a pythonPkgs key. Is my way of handling this non standard maybe? ๐Ÿค”

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions