2018-11-21 11:20:14 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2021-03-13 21:41:48 +00:00
|
|
|
, pythonOlder
|
|
|
|
, setuptools-scm
|
2021-03-24 17:20:43 +00:00
|
|
|
, typing-extensions
|
2021-03-13 21:41:48 +00:00
|
|
|
, toml
|
2019-04-01 15:50:33 +01:00
|
|
|
, zipp
|
2018-11-21 11:20:14 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "importlib-metadata";
|
2021-05-08 23:01:47 +01:00
|
|
|
version = "4.0.1";
|
2021-03-13 21:41:48 +00:00
|
|
|
disabled = pythonOlder "3.6";
|
2018-11-21 11:20:14 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
pname = "importlib_metadata";
|
|
|
|
inherit version;
|
2021-05-08 23:01:47 +01:00
|
|
|
sha256 = "sha256-jFARluSfud9d9DgzvbHkMo9khHdj7IpQcDFItzeE1YE=";
|
2018-11-21 11:20:14 +00:00
|
|
|
};
|
|
|
|
|
2021-03-13 21:41:48 +00:00
|
|
|
nativeBuildInputs = [ setuptools-scm ];
|
2018-11-21 11:20:14 +00:00
|
|
|
|
2021-03-24 17:20:43 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
toml
|
|
|
|
zipp
|
|
|
|
] ++ lib.optionals (pythonOlder "3.8") [
|
|
|
|
typing-extensions
|
|
|
|
];
|
2019-04-01 15:50:33 +01:00
|
|
|
|
2021-03-13 21:41:48 +00:00
|
|
|
# Cyclic dependencies due to pyflakefs
|
|
|
|
doCheck = false;
|
|
|
|
pythonImportsCheck = [ "importlib_metadata" ];
|
2020-02-23 13:05:13 +00:00
|
|
|
|
2018-11-21 11:20:14 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Read metadata from Python packages";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://importlib-metadata.readthedocs.io/";
|
2018-11-21 11:20:14 +00:00
|
|
|
license = licenses.asl20;
|
2021-03-13 21:41:48 +00:00
|
|
|
maintainers = with maintainers; [ fab ];
|
2018-11-21 11:20:14 +00:00
|
|
|
};
|
2019-04-01 15:50:33 +01:00
|
|
|
}
|