Merge pull request #236704 from fabaff/py-multicodec-pytest-runner

python311Packages.py-multicodec: remove pytest-runner
This commit is contained in:
Fabian Affolter 2023-06-09 09:48:17 +02:00 committed by GitHub
commit 0fd7e6d4e9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,10 +1,9 @@
{ lib { lib
, buildPythonPackage , buildPythonPackage
, fetchFromGitHub , fetchFromGitHub
, pytest-runner , morphys
, pytestCheckHook , pytestCheckHook
, pythonOlder , pythonOlder
, morphys
, six , six
, varint , varint
}: }:
@ -12,36 +11,39 @@
buildPythonPackage rec { buildPythonPackage rec {
pname = "py-multicodec"; pname = "py-multicodec";
version = "0.2.1"; version = "0.2.1";
disabled = pythonOlder "3.5"; format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "multiformats"; owner = "multiformats";
repo = pname; repo = pname;
rev = "v${version}"; rev = "refs/tags/v${version}";
hash = "sha256-2aK+bfhqCMqSO+mtrHIfNQmQpQHpwd7yHseI/3O7Sp4="; hash = "sha256-2aK+bfhqCMqSO+mtrHIfNQmQpQHpwd7yHseI/3O7Sp4=";
}; };
# Error when not substituting: # Error when not substituting:
# Failed: [pytest] section in setup.cfg files is no longer supported, change to [tool:pytest] instead. # Failed: [pytest] section in setup.cfg files is no longer supported, change to [tool:pytest] instead.
postPatch = '' postPatch = ''
substituteInPlace setup.cfg --replace "[pytest]" "[tool:pytest]" substituteInPlace setup.cfg \
--replace "[pytest]" "[tool:pytest]"
substituteInPlace setup.py \
--replace "'pytest-runner'," ""
''; '';
nativeBuildInputs = [
pytest-runner
];
propagatedBuildInputs = [ propagatedBuildInputs = [
varint
six
morphys morphys
six
varint
]; ];
nativeCheckInputs = [ nativeCheckInputs = [
pytestCheckHook pytestCheckHook
]; ];
pythonImportsCheck = [ "multicodec" ]; pythonImportsCheck = [
"multicodec"
];
meta = with lib; { meta = with lib; {
description = "Compact self-describing codecs"; description = "Compact self-describing codecs";