python39Packages.debtcollector: init at 2.3.0

This commit is contained in:
Sandro Jäckel 2021-09-11 12:08:00 +02:00
parent 7bee25daa2
commit bb915c3840
No known key found for this signature in database
GPG key ID: 3AF5A43A3EECC2E5
3 changed files with 63 additions and 0 deletions

View file

@ -0,0 +1,31 @@
{ lib, buildPythonPackage, fetchPypi, pbr, six, wrapt, callPackage }:
buildPythonPackage rec {
pname = "debtcollector";
version = "2.3.0";
src = fetchPypi {
inherit pname version;
sha256 = "c7a9fac814ab5904e23905516b18356cc907e7d27c05da58d37103f001967846";
};
nativeBuildInputs = [ pbr ];
propagatedBuildInputs = [ six wrapt ];
# check in passthru.tests.pytest to escape infinite recursion with other oslo components
doCheck = false;
passthru.tests = {
pytest = callPackage ./tests.nix { };
};
pythonImportsCheck = [ "debtcollector" ];
meta = with lib; {
description = "A collection of Python deprecation patterns and strategies that help you collect your technical debt in a non-destructive manner";
homepage = "https://github.com/openstack/debtcollector";
license = licenses.asl20;
maintainers = teams.openstack.members;
};
}

View file

@ -0,0 +1,30 @@
{ stdenv
, buildPythonPackage
, debtcollector
, stestr
}:
buildPythonPackage rec {
pname = "debtcollector-tests";
inherit (debtcollector) version;
src = debtcollector.src;
postPatch = ''
# only a small portion of the listed packages are actually needed for running the tests
# so instead of removing them one by one remove everything
rm test-requirements.txt
'';
dontBuild = true;
dontInstall = true;
checkInputs = [
debtcollector
stestr
];
checkPhase = ''
stestr run
'';
}

View file

@ -1884,6 +1884,8 @@ in {
debian-inspector = callPackage ../development/python-modules/debian-inspector { };
debtcollector = callPackage ../development/python-modules/debtcollector { };
debts = callPackage ../development/python-modules/debts { };
debugpy = callPackage ../development/python-modules/debugpy { };