python36Packages.traitlets, pythonPackages.traitlets: 5.0.5 -> 4.3.3
Version 5.x of traitlets requires Python 3.7, so it doesn't build on Python 3.6. This commit downgrades traitlets to 4.3.3 on Python versions older than 3.7 so that it can still be used.
This commit is contained in:
parent
50accd8aff
commit
ce5b550d01
|
@ -0,0 +1,36 @@
|
|||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchPypi
|
||||
, glibcLocales
|
||||
, pytest
|
||||
, mock
|
||||
, ipython_genutils
|
||||
, decorator
|
||||
, enum34
|
||||
, pythonOlder
|
||||
, six
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "traitlets";
|
||||
version = "4.3.3";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "d023ee369ddd2763310e4c3eae1ff649689440d4ae59d7485eb4cfbbe3e359f7";
|
||||
};
|
||||
|
||||
checkInputs = [ glibcLocales pytest mock ];
|
||||
propagatedBuildInputs = [ ipython_genutils decorator six ] ++ lib.optional (pythonOlder "3.4") enum34;
|
||||
|
||||
checkPhase = ''
|
||||
LC_ALL="en_US.UTF-8" py.test
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Traitlets Python config system";
|
||||
homepage = "http://ipython.org/";
|
||||
license = lib.licenses.bsd3;
|
||||
maintainers = with lib.maintainers; [ ];
|
||||
};
|
||||
}
|
|
@ -1,6 +1,5 @@
|
|||
{ lib
|
||||
, buildPythonPackage
|
||||
, isPy27
|
||||
, fetchPypi
|
||||
, glibcLocales
|
||||
, pytest
|
||||
|
@ -15,7 +14,7 @@
|
|||
buildPythonPackage rec {
|
||||
pname = "traitlets";
|
||||
version = "5.0.5";
|
||||
disabled = isPy27;
|
||||
disabled = pythonOlder "3.7";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
|
@ -23,7 +22,7 @@ buildPythonPackage rec {
|
|||
};
|
||||
|
||||
checkInputs = [ glibcLocales pytest mock ];
|
||||
propagatedBuildInputs = [ ipython_genutils decorator six ] ++ lib.optional (pythonOlder "3.4") enum34;
|
||||
propagatedBuildInputs = [ ipython_genutils decorator six ];
|
||||
|
||||
checkPhase = ''
|
||||
LC_ALL="en_US.UTF-8" py.test
|
||||
|
|
|
@ -7437,7 +7437,10 @@ in {
|
|||
|
||||
trackpy = callPackage ../development/python-modules/trackpy { };
|
||||
|
||||
traitlets = callPackage ../development/python-modules/traitlets { };
|
||||
traitlets = if pythonOlder "3.7" then
|
||||
callPackage ../development/python-modules/traitlets/4.nix { }
|
||||
else
|
||||
callPackage ../development/python-modules/traitlets { };
|
||||
|
||||
traits = callPackage ../development/python-modules/traits { };
|
||||
|
||||
|
|
Loading…
Reference in New Issue