mirror of
https://github.com/vale981/poetry2nix
synced 2025-03-04 16:51:40 -05:00
mk-poetry-dep: Add pep508 evaluation to dependency selection
Poetry 1.1.0 changed the marker format in https://github.com/python-poetry/poetry/pull/2361
This commit is contained in:
parent
1bebfa70f8
commit
99cdaa7cca
2 changed files with 4 additions and 2 deletions
|
@ -106,7 +106,7 @@ lib.makeScope pkgs.newScope (self: {
|
|||
in
|
||||
{
|
||||
mkPoetryDep = self.callPackage ./mk-poetry-dep.nix {
|
||||
inherit pkgs lib python poetryLib;
|
||||
inherit pkgs lib python poetryLib evalPep508;
|
||||
};
|
||||
poetry = if __isBootstrap then null else poetryPkg;
|
||||
# The canonical name is setuptools-scm
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
, python
|
||||
, buildPythonPackage
|
||||
, poetryLib
|
||||
, evalPep508
|
||||
}:
|
||||
{ name
|
||||
, version
|
||||
|
@ -126,8 +127,9 @@ pythonPackages.callPackage
|
|||
n: v:
|
||||
let
|
||||
constraints = v.python or "";
|
||||
pep508Markers = v.markers or "";
|
||||
in
|
||||
compat constraints
|
||||
compat constraints && evalPep508 pep508Markers
|
||||
)
|
||||
dependencies
|
||||
);
|
||||
|
|
Loading…
Add table
Reference in a new issue