python3Packages.coverage: 7.8.0 -> 7.8.2 (#414571)

This commit is contained in:
dotlambda 2025-06-08 13:22:42 -07:00 committed by GitHub
commit 46d385b56e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,34 +1,81 @@
{ {
lib, lib,
buildPythonPackage, buildPythonPackage,
fetchPypi, fetchFromGitHub,
mock, flaky,
hypothesis,
pytest-xdist,
pytestCheckHook,
pythonOlder, pythonOlder,
setuptools, setuptools,
tomli,
}: }:
buildPythonPackage rec { buildPythonPackage rec {
pname = "coverage"; pname = "coverage";
version = "7.8.0"; version = "7.8.2";
pyproject = true; pyproject = true;
# uses f strings src = fetchFromGitHub {
disabled = pythonOlder "3.5"; owner = "nedbat";
repo = "coveragepy";
src = fetchPypi { tag = version;
inherit pname version; hash = "sha256-PCMGxyG5zIc8iigi9BsuhyuyQindZnewqTgxErT/jHw=";
hash = "sha256-ej1is7A7S2/UGghfNXSHTPlGy0YE0rTT6NyozVcMpQE=";
}; };
nativeBuildInputs = [ setuptools ]; postPatch = ''
# don't write to Nix store
substituteInPlace tests/conftest.py \
--replace-fail 'if WORKER == "none":' "if False:"
'';
# No tests in archive build-system = [ setuptools ];
doCheck = false;
nativeCheckInputs = [ mock ]; optional-dependencies = {
toml = lib.optionals (pythonOlder "3.11") [
tomli
];
};
nativeCheckInputs = [
flaky
hypothesis
pytest-xdist
pytestCheckHook
];
preCheck = ''
export PATH="$PATH:$out/bin"
# import from $out
rm -r coverage
'';
disabledTests = [
"test_all_our_source_files"
"test_doctest"
"test_files_up_one_level"
"test_get_encoded_zip_files"
"test_metadata"
"test_more_metadata"
"test_multi"
"test_no_duplicate_packages"
"test_xdist_sys_path_nuttiness_is_fixed"
"test_zipfile"
];
disabledTestPaths = [
"tests/test_debug.py"
"tests/test_plugins.py"
"tests/test_process.py"
"tests/test_report.py"
"tests/test_venv.py"
];
meta = { meta = {
description = "Code coverage measurement for python"; changelog = "https://github.com/nedbat/coveragepy/blob/${src.tag}/CHANGES.rst";
homepage = "https://coverage.readthedocs.io/"; description = "Code coverage measurement for Python";
license = lib.licenses.bsd3; homepage = "https://github.com/nedbat/coveragepy";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ dotlambda ];
}; };
} }