NixOS / nix

Nix, the purely functional package manager

Home Page:https://nixos.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Nix Shell Issue: Poetry 'Dulwich' Dependency

chandler-scott opened this issue · comments

Describe the bug
I am unable to run a nix shell with python3.* and poetry. When I try, I receive an error about a dulwich dependency.

dulwich<0.22.0,>=0.21.2 not satisfied by version 0.22.1

Steps To Reproduce
In a shell.nix file:

{ pkgs ? import <nixpkgs> {} }:

pkgs.mkShell {
  buildInputs = [
    pkgs.python311
    pkgs.poetry
  ];

  shellHook = ''
    echo "Environment ready."
  '';
}

Or via command line:
nix-shell -p python3 poetry

Expected behavior
Should open a nix shell with python3.* and poetry packages.

This is a new Nix installation from the official download website.

I installed Nix via:
sh <(curl -L https://nixos.org/nix/install) --daemon

This seems like a Nixpkgs issue. I can't replicate this.

I changed my shell.nix to the tutorial's shell.nix and was able to open a shell successfully.

let
  nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-23.11";
  pkgs = import nixpkgs { config = {}; overlays = []; };
in

pkgs.mkShell {
  buildInputs = [
    pkgs.python311
    pkgs.poetry
  ];

  shellHook = ''
    echo "Environment ready for Embedded Development."
  '';
}

Faced this today with unstable.^