From bf9fcead6d74763d9dd18d1c49fe4f440527d290 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Thu, 6 Jul 2023 04:37:29 +0000 Subject: [PATCH 1/4] python310Packages.returns: 0.20.0 -> 0.21.0 --- pkgs/development/python-modules/returns/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/returns/default.nix b/pkgs/development/python-modules/returns/default.nix index d12e4ccf1f5e..e408efb4d024 100644 --- a/pkgs/development/python-modules/returns/default.nix +++ b/pkgs/development/python-modules/returns/default.nix @@ -16,14 +16,14 @@ buildPythonPackage rec { pname = "returns"; - version = "0.20.0"; + version = "0.21.0"; format = "pyproject"; src = fetchFromGitHub { owner = "dry-python"; repo = "returns"; rev = "refs/tags/${version}"; - hash = "sha256-28WYjrjmu3hQ8+Snuvl3ykTd86eWYI97AE60p6SVwDQ="; + hash = "sha256-oYOCoh/pF2g4KGWC2mEnFD+zm2CKL+3x5JjzuZ3QHVQ="; }; postPatch = '' From f9edead13e65794d560f788d85f56cbeaca81e88 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Thu, 6 Jul 2023 08:42:55 +0200 Subject: [PATCH 2/4] python310Packages.returns: add changelog to meta --- pkgs/development/python-modules/returns/default.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/returns/default.nix b/pkgs/development/python-modules/returns/default.nix index e408efb4d024..0d356de77f79 100644 --- a/pkgs/development/python-modules/returns/default.nix +++ b/pkgs/development/python-modules/returns/default.nix @@ -56,12 +56,15 @@ buildPythonPackage rec { trio ]; - pytestFlagsArray = [ "--ignore=typesafety" ]; + pytestFlagsArray = [ + "--ignore=typesafety" + ]; meta = with lib; { description = "Make your functions return something meaningful, typed, and safe!"; homepage = "https://github.com/dry-python/returns"; + changelog = "https://github.com/dry-python/returns/blob/${version}/CHANGELOG.md"; license = licenses.bsd2; - maintainers = [ maintainers.jessemoore ]; + maintainers = with maintainers; [ jessemoore ]; }; } From 3af6ee75ce71131511bd6021b9f97e9f7cd4916f Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Thu, 6 Jul 2023 08:45:16 +0200 Subject: [PATCH 3/4] python310Packages.returns: disable on unsupported Python releases --- pkgs/development/python-modules/returns/default.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/returns/default.nix b/pkgs/development/python-modules/returns/default.nix index 0d356de77f79..098ae334ccd0 100644 --- a/pkgs/development/python-modules/returns/default.nix +++ b/pkgs/development/python-modules/returns/default.nix @@ -1,14 +1,15 @@ { lib , anyio -, curio , buildPythonPackage +, curio , fetchFromGitHub , httpx , hypothesis , poetry-core -, pytestCheckHook , pytest-aio , pytest-subtests +, pytestCheckHook +, pythonOlder , setuptools , trio , typing-extensions @@ -19,6 +20,8 @@ buildPythonPackage rec { version = "0.21.0"; format = "pyproject"; + disabled = pythonOlder "3.7"; + src = fetchFromGitHub { owner = "dry-python"; repo = "returns"; From f7d24d71aa15b751d6915802e60a7844a123cd16 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Thu, 6 Jul 2023 08:47:17 +0200 Subject: [PATCH 4/4] python311Packages.returns: add pythonImportsCheck --- pkgs/development/python-modules/returns/default.nix | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/returns/default.nix b/pkgs/development/python-modules/returns/default.nix index 098ae334ccd0..0b54d62ba569 100644 --- a/pkgs/development/python-modules/returns/default.nix +++ b/pkgs/development/python-modules/returns/default.nix @@ -43,10 +43,6 @@ buildPythonPackage rec { typing-extensions ]; - preCheck = '' - rm -rf returns/contrib/mypy - ''; - nativeCheckInputs = [ anyio curio @@ -59,6 +55,14 @@ buildPythonPackage rec { trio ]; + preCheck = '' + rm -rf returns/contrib/mypy + ''; + + pythonImportsCheck = [ + "returns" + ]; + pytestFlagsArray = [ "--ignore=typesafety" ];