2018-11-21 12:20:14 +01:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2019-04-01 16:50:33 +02:00
|
|
|
, setuptools_scm
|
|
|
|
, zipp
|
2018-11-21 12:20:14 +01:00
|
|
|
, pathlib2
|
|
|
|
, contextlib2
|
2019-04-01 16:50:33 +02:00
|
|
|
, configparser
|
2018-11-21 12:20:14 +01:00
|
|
|
, isPy3k
|
|
|
|
, importlib-resources
|
2019-04-01 16:50:33 +02:00
|
|
|
, packaging
|
2018-11-21 12:20:14 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "importlib-metadata";
|
2019-10-16 18:34:20 +02:00
|
|
|
version = "0.23";
|
2018-11-21 12:20:14 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
pname = "importlib_metadata";
|
|
|
|
inherit version;
|
2019-10-16 18:34:20 +02:00
|
|
|
sha256 = "09mdqdfv5rdrwz80jh9m379gxmvk2vhjfz0fg53hid00icvxf65a";
|
2018-11-21 12:20:14 +01:00
|
|
|
};
|
|
|
|
|
2019-04-01 16:50:33 +02:00
|
|
|
nativeBuildInputs = [ setuptools_scm ];
|
2018-11-21 12:20:14 +01:00
|
|
|
|
2019-04-01 16:50:33 +02:00
|
|
|
propagatedBuildInputs = [ zipp ]
|
|
|
|
++ lib.optionals (!isPy3k) [ pathlib2 contextlib2 configparser ];
|
|
|
|
|
|
|
|
checkInputs = [ importlib-resources packaging ];
|
2018-11-21 12:20:14 +01:00
|
|
|
|
2019-06-15 19:30:38 +02:00
|
|
|
# Two failing tests: https://gitlab.com/python-devs/importlib_metadata/issues/72
|
|
|
|
doCheck = false;
|
|
|
|
|
2018-11-21 12:20:14 +01:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Read metadata from Python packages";
|
|
|
|
homepage = https://importlib-metadata.readthedocs.io/;
|
|
|
|
license = licenses.asl20;
|
|
|
|
};
|
2019-04-01 16:50:33 +02:00
|
|
|
}
|