Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

default.nix flake-compat is broken #285

Closed
Pacman99 opened this issue May 16, 2021 · 7 comments · Fixed by #286
Closed

default.nix flake-compat is broken #285

Pacman99 opened this issue May 16, 2021 · 7 comments · Fixed by #286
Labels
bug Something isn't working

Comments

@Pacman99
Copy link
Member

Pacman99 commented May 16, 2021

Expected Behavior

You should be able to use the repo's default.nix to access the shell or build your configuration.

Current Behavior

It gives the following error:

error: getting status of '/nix/store/flake.nix': No such file or directory

       … while evaluating 'callLocklessFlake'

       at /nix/store/0n6nqnb6b6cs3hjqprq9k10a1nc2rgiy-source/default.nix:75:23:

           74|
           75|   callLocklessFlake = flakeSrc:
             |                       ^
           76|     let

       … from call site

       at /nix/store/0n6nqnb6b6cs3hjqprq9k10a1nc2rgiy-source/default.nix:173:10:

          172|     if !(builtins.pathExists lockFilePath)
          173|     then callLocklessFlake rootSrc
             |          ^
          174|     else if lockFile.version == 4

       … while evaluating the attribute 'defaultNix'

       at /nix/store/0n6nqnb6b6cs3hjqprq9k10a1nc2rgiy-source/default.nix:182:5:

          181|   rec {
          182|     defaultNix =
             |     ^
          183|       result

Possible Solution

Steps to Reproduce

  1. Run the recommended command: nix-shell https://github.com/divnix/devos/archive/core.tar.gz -A shell --show-trace

Context

This doesn't affect shell.nix. So if you clone the repository and run nix-shell that will go directly to shell.nix and theres no problem. The issue seems to occur when you use default.nix.

cc @narice

@Pacman99 Pacman99 added the bug Something isn't working label May 16, 2021
@Pacman99
Copy link
Member Author

I don't actually know if this is a APIv1 problem, I remember experiencing this a while back. I had assumed it was because of my repository's changes. I didn't realize it was happening to the repo in general

@Pacman99
Copy link
Member Author

@narice can you check if #286 fixes the issue for you too? It seems to help for me.

@nova-nowiz
Copy link
Contributor

Yes! it is building right now ;) awesome work!

@nova-nowiz
Copy link
Contributor

However I still have an issue after that:

fkl get core
error: cannot find flake attribute 'github:divnix/devos/core#defaultTemplate'

which is normal as in the flake there is not indeed this attribute, it was commented out during the API update I guess ;)

@nova-nowiz
Copy link
Contributor

I would really like to help on this as this looks like a trivial thing but I cannot find where the fkl utility is defined x)
It is in this repository?

@nova-nowiz
Copy link
Contributor

I went full detective mode digga was not named digga before the in-tree lib got removed.
Here is the relevent file: https://github.com/divnix/digga/blob/master/src/pkgs-lib/shell/flk.sh

@nova-nowiz
Copy link
Contributor

I opened an issue here: #12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants