Merge pull request #236829 from fabaff/pycategories-pytest-runner

python311Packages.pycategories: remove pytest-runner
This commit is contained in:
Fabian Affolter 2023-06-09 23:06:26 +02:00 committed by GitHub
commit c812761559
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,34 +1,42 @@
{ buildPythonPackage { lib
, buildPythonPackage
, callPackage , callPackage
, pytest-cov
, fetchPypi , fetchPypi
, lib , pytestCheckHook
, pytest
, pythonOlder , pythonOlder
, pytest-runner
}: }:
buildPythonPackage rec { buildPythonPackage rec {
pname = "pycategories"; pname = "pycategories";
version = "1.2.0"; version = "1.2.0";
disabled = pythonOlder "3.4"; format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchPypi { src = fetchPypi {
inherit pname version; inherit pname version;
sha256 = "bd70ecb5e94e7659e564ea153f0c7673291dc37c526c246800fc08d6c5378099"; hash = "sha256-vXDstelOdlnlZOoVPwx2cykdw3xSbCRoAPwI1sU3gJk=";
}; };
nativeBuildInputs = [ pytest-runner ]; postPatch = ''
substituteInPlace setup.py \
--replace "'pytest-runner'," ""
substituteInPlace setup.cfg \
--replace "--cov-report term --cov=categories" ""
'';
# Is private because the author states it's unmaintained # Is private because the author states it's unmaintained
# and shouldn't be used in production code # and shouldn't be used in production code
propagatedBuildInputs = [ (callPackage ./infix.nix { }) ]; propagatedBuildInputs = [ (callPackage ./infix.nix { }) ];
nativeCheckInputs = [ pytest pytest-cov ]; nativeCheckInputs = [
pytestCheckHook
];
meta = with lib; { meta = with lib; {
homepage = "https://gitlab.com/danielhones/pycategories";
description = "Implementation of some concepts from category theory"; description = "Implementation of some concepts from category theory";
homepage = "https://gitlab.com/danielhones/pycategories";
changelog = "https://gitlab.com/danielhones/pycategories/-/blob/v${version}/CHANGELOG.rst";
license = licenses.mit; license = licenses.mit;
maintainers = with maintainers; [ dmvianna ]; maintainers = with maintainers; [ dmvianna ];
}; };