1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-18 03:30:45 +00:00

Merge pull request #324631 from pbsds/bump-whenever-1720115429

python311Packages.whenever: 0.5.2 -> 0.6.1
This commit is contained in:
Peder Bergebakken Sundt 2024-07-19 14:43:45 +02:00 committed by GitHub
commit de569508c4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,11 +1,15 @@
{
lib,
stdenv,
fetchFromGitHub,
pythonOlder,
rustPlatform,
cargo,
rustc,
libiconv,
buildPythonPackage,
poetry-core,
backports-zoneinfo,
tzdata,
setuptools,
setuptools-rust,
pytestCheckHook,
pytest-mypy-plugins,
hypothesis,
@ -14,38 +18,54 @@
buildPythonPackage rec {
pname = "whenever";
version = "0.5.2";
version = "0.6.1";
pyproject = true;
disabled = pythonOlder "3.8";
disabled = pythonOlder "3.9";
src = fetchFromGitHub {
owner = "ariebovenberg";
repo = "whenever";
rev = "refs/tags/${version}";
hash = "sha256-bG8LV+r5MjA1JwBHWy9/Io4daldAlyEGYNLW+5ITuOw=";
hash = "sha256-uUjQtaqPO/Ie7vVddQhc3dxORX2PxNRaDJzCr+vieUo=";
};
postPatch = ''
# unrecognized arguments since we don't use pytest-benchmark in nixpkgs
substituteInPlace pytest.ini \
--replace-fail '--benchmark-disable' '#--benchmark-disable'
'';
cargoDeps = rustPlatform.fetchCargoTarball {
inherit src;
hash = "sha256-8U3pGKY9UQ0JpzUn3Ny6YSD3wzXPDi1pupD5fpEJFvw=";
};
build-system = [ poetry-core ];
build-system = [
setuptools
setuptools-rust
rustPlatform.cargoSetupHook
cargo
rustc
];
dependencies = [ tzdata ] ++ lib.optionals (pythonOlder "3.9") [ backports-zoneinfo ];
buildInputs = lib.optionals stdenv.isDarwin [
libiconv
];
nativeCheckInputs = [
pytestCheckHook
pytest-mypy-plugins
# pytest-benchmark # developer sanity check, should not block distribution
hypothesis
freezegun
];
disabledTestPaths = [
# benchmarks
"benchmarks/python/test_date.py"
"benchmarks/python/test_instant.py"
"benchmarks/python/test_local_datetime.py"
"benchmarks/python/test_zoned_datetime.py"
];
pythonImportsCheck = [ "whenever" ];
# early TDD, many tests are failing
# a bunch of failures, including an assumption of what the timezone on the host is
# TODO: try enabling on bump
doCheck = false;