2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
packaging,
|
|
|
|
pyparsing,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
setuptools-scm,
|
2022-05-18 14:49:53 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pip-requirements-parser";
|
2023-03-15 16:39:30 +00:00
|
|
|
version = "32.0.1";
|
2022-05-18 14:49:53 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "nexB";
|
|
|
|
repo = pname;
|
2023-03-15 16:39:30 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-UMrwDXxk+sD3P2jk7s95y4OX6DRBjWWZZ8IhkR6tnZ4=";
|
2022-05-18 14:49:53 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
dontConfigure = true;
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeBuildInputs = [ setuptools-scm ];
|
2022-05-18 14:49:53 +00:00
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
packaging
|
2023-03-15 16:39:30 +00:00
|
|
|
pyparsing
|
2022-05-18 14:49:53 +00:00
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2022-05-18 14:49:53 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "pip_requirements_parser" ];
|
2022-05-18 14:49:53 +00:00
|
|
|
|
2023-03-15 16:39:30 +00:00
|
|
|
disabledTests = [
|
|
|
|
"test_RequirementsFile_to_dict"
|
|
|
|
"test_RequirementsFile_dumps_unparse"
|
|
|
|
"test_legacy_version_is_deprecated"
|
|
|
|
];
|
|
|
|
|
2022-05-18 14:49:53 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Module to parse pip requirements";
|
|
|
|
homepage = "https://github.com/nexB/pip-requirements-parser";
|
2022-12-17 10:02:37 +00:00
|
|
|
changelog = "https://github.com/nexB/pip-requirements-parser/blob/v${version}/CHANGELOG.rst";
|
2022-05-18 14:49:53 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|