From 111e3a55a6b047234b64cbf073dff07549c7f0fa Mon Sep 17 00:00:00 2001 From: natsukium Date: Tue, 30 May 2023 00:26:42 +0900 Subject: [PATCH 1/2] python3Packages.filterpy: 1.4.5 -> unstable-2022-08-23 Diff: https://github.com/rlabbe/filterpy/compare/1.4.5...3b51149ebcff0401ff1e10bf08ffca7b6bbc4a33 --- .../python-modules/filterpy/default.nix | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/pkgs/development/python-modules/filterpy/default.nix b/pkgs/development/python-modules/filterpy/default.nix index 877bd02ed31b..04304913eb5e 100644 --- a/pkgs/development/python-modules/filterpy/default.nix +++ b/pkgs/development/python-modules/filterpy/default.nix @@ -1,6 +1,6 @@ { lib , buildPythonPackage -, fetchPypi +, fetchFromGitHub , numpy , scipy , matplotlib @@ -8,15 +8,16 @@ , isPy3k }: -buildPythonPackage rec { - version = "1.4.5"; +buildPythonPackage { + version = "unstable-2022-08-23"; pname = "filterpy"; disabled = !isPy3k; - src = fetchPypi { - inherit pname version; - extension = "zip"; - sha256 = "4f2a4d39e4ea601b9ab42b2db08b5918a9538c168cff1c6895ae26646f3d73b1"; + src = fetchFromGitHub { + owner = "rlabbe"; + repo = "filterpy"; + rev = "3b51149ebcff0401ff1e10bf08ffca7b6bbc4a33"; + hash = "sha256-KuuVu0tqrmQuNKYmDmdy+TU6BnnhDxh4G8n9BGzjGag="; }; nativeCheckInputs = [ pytest ]; From 46a649030ab875e645dcd3d6935a3bc225574cd9 Mon Sep 17 00:00:00 2001 From: natsukium Date: Tue, 30 May 2023 00:29:42 +0900 Subject: [PATCH 2/2] python3Packages.filterpy: fix formatting - add format - use pytestCheckHook - enable all tests --- .../python-modules/filterpy/default.nix | 21 +++++++++++-------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/filterpy/default.nix b/pkgs/development/python-modules/filterpy/default.nix index 04304913eb5e..86ea56f33347 100644 --- a/pkgs/development/python-modules/filterpy/default.nix +++ b/pkgs/development/python-modules/filterpy/default.nix @@ -4,13 +4,15 @@ , numpy , scipy , matplotlib -, pytest +, pytestCheckHook , isPy3k }: buildPythonPackage { - version = "unstable-2022-08-23"; pname = "filterpy"; + version = "unstable-2022-08-23"; + format = "setuptools"; + disabled = !isPy3k; src = fetchFromGitHub { @@ -20,14 +22,15 @@ buildPythonPackage { hash = "sha256-KuuVu0tqrmQuNKYmDmdy+TU6BnnhDxh4G8n9BGzjGag="; }; - nativeCheckInputs = [ pytest ]; - propagatedBuildInputs = [ numpy scipy matplotlib ]; + nativeCheckInputs = [ + pytestCheckHook + ]; - # single test fails (even on master branch of repository) - # project does not use CI - checkPhase = '' - pytest --ignore=filterpy/common/tests/test_discretization.py - ''; + propagatedBuildInputs = [ + numpy + scipy + matplotlib + ]; meta = with lib; { homepage = "https://github.com/rlabbe/filterpy";