8000 Nested flake source paths broken · Issue #13164 · NixOS/nix · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Nested flake source paths broken #13164
Closed
@packruler

Description

@packruler

Describe the bug

I noticed recently that my NixOS config was getting a new error about the modules I have built with nested flake references were not building because the path to the module source was incorrect.

Steps To Reproduce

Create a directory with multiple nested flakes. Here is a rough directory structure as an example:

example_project/
├─ module_a/
│  ├─ module_b/
│  │  ├─ flake.nix
│  ├─ flake.nix
├─ flake.nix

Now assume that example_project/flake.nix resembles this:

{
  inputs.module_a.url = "./module_a";
  ...
}

example_project/module_a/flake.nix resembles this:

{
  inputs.module_b.url = "./module_b";
  ...
}

Expected behavior

It is expected that the reference to module_b's source in the nix store would be similar to /nix/store/<hash>-source/module_a/module_b and the build process would be successful.

Actual behavior

The file path attempted for loading module_b has an additional reference to module_a's sub directory, which is similar to /nix/store/<hash>-source/module_a/module_a/module_b.

Metadata

nix-env (Nix) 2.28.3

Additional context

I was able to use nix-env (Nix) 2.27.1 to successfully build the modules again.

I am fairly certain the source of this issue was caused by this update: 2109a5a

Checklist


Add 👍 to issues you find important.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0