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

Add support for nix 2.19 path-info #68

Merged
merged 1 commit into from
Nov 28, 2023
Merged

Add support for nix 2.19 path-info #68

merged 1 commit into from
Nov 28, 2023

Conversation

GrigorenkoPV
Copy link
Contributor

Fixes #67

@utdemir
Copy link
Owner

utdemir commented Nov 28, 2023

Thanks!

@utdemir utdemir enabled auto-merge (rebase) November 28, 2023 01:32
@utdemir utdemir merged commit 8aa384d into utdemir:main Nov 28, 2023
@SuperSandro2000
Copy link

Tested this with the following overlay and works like a charm

    haskellPackages = prev.haskellPackages.override (oldArgs: {
      overrides = lib.composeExtensions (oldArgs.overrides or (_: _: { }))
        (hfinal: hprev: {Unused lambda argument: hfinal
          nix-tree = haskell.lib.doJailbreak (hprev.nix-tree.overrideAttrs ({ patches ? [ ], ... }: {
            patches = patches ++ [
              # nix 2.19 compatibility
              (fetchpatch {
                url = "https://github.com/utdemir/nix-tree/pull/68.patch";
                hash = "sha256-70Xo88ZWzWUYM0qxbW64kYaVwHaYkS2dQWmBGCkL0oA=";
              })
            ];
          }));
        });
    });

@lierdakil
Copy link

I'm just passing by, but IIUC this code will break the moment it encounters invalid paths, because obj2LegacyArray doesn't handle the Null value, which can happen according to https://nixos.org/manual/nix/stable/release-notes/rl-2.19.

@GrigorenkoPV
Copy link
Contributor Author

I'm just passing by, but IIUC this code will break the moment it encounters invalid paths, because obj2LegacyArray doesn't handle the Null value, which can happen according to https://nixos.org/manual/nix/stable/release-notes/rl-2.19.

You are correct, thank you! In reality this simply resulted in a less informative error message. Not catastrophic, but not very desirable either. Anyways, I have submitted a fix #69.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support new path-info syntax introduced in nix 2.19
4 participants