From 0e92f9ebceddcea2f9243cd17abc46ac99745c57 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 19 Feb 2023 17:08:47 +0100 Subject: [PATCH 1/6] python311Packages.boltons: add changelog to meta --- pkgs/development/python-modules/boltons/default.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/boltons/default.nix b/pkgs/development/python-modules/boltons/default.nix index 19d69546abb8..0456a9a1933c 100644 --- a/pkgs/development/python-modules/boltons/default.nix +++ b/pkgs/development/python-modules/boltons/default.nix @@ -17,7 +17,7 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "mahmoud"; repo = "boltons"; - rev = version; + rev = "refs/tags/${version}"; hash = "sha256-8HO7X2PQEbQIQsCa2cMHQI3rlofVT22GYrWNXY34MLk="; }; @@ -42,7 +42,6 @@ buildPythonPackage rec { ]; meta = with lib; { - homepage = "https://github.com/mahmoud/boltons"; description = "Constructs, recipes, and snippets extending the Python standard library"; longDescription = '' Boltons is a set of over 200 BSD-licensed, pure-Python utilities @@ -59,6 +58,8 @@ buildPythonPackage rec { - A full-featured TracebackInfo type, for representing stack traces, in tbutils ''; + homepage = "https://github.com/mahmoud/boltons"; + changelog = "https://github.com/mahmoud/boltons/blob/${version}/CHANGELOG.md"; license = licenses.bsd3; maintainers = with maintainers; [ twey ]; }; From fff94b111d928c0f03f6c4a5da0a6ebeada37e05 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 19 Feb 2023 17:17:09 +0100 Subject: [PATCH 2/6] python311Packages.boltons: disable failing test on Python 3.11 --- pkgs/development/python-modules/boltons/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/development/python-modules/boltons/default.nix b/pkgs/development/python-modules/boltons/default.nix index 0456a9a1933c..1c65fed86bbf 100644 --- a/pkgs/development/python-modules/boltons/default.nix +++ b/pkgs/development/python-modules/boltons/default.nix @@ -41,6 +41,11 @@ buildPythonPackage rec { "boltons" ]; + disabledTests = lib.optionals (pythonAtLeast "3.11") [ + # https://github.com/mahmoud/boltons/issues/326 + "test_frozendict_api" + ]; + meta = with lib; { description = "Constructs, recipes, and snippets extending the Python standard library"; longDescription = '' From d7bf4cb9020d0c369fc67f559b5a31bae0619172 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 19 Feb 2023 18:01:17 +0100 Subject: [PATCH 3/6] python311Packages.glom: add changelog to meta --- pkgs/development/python-modules/glom/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/glom/default.nix b/pkgs/development/python-modules/glom/default.nix index 38f17c9ed8cc..41ae225293cf 100644 --- a/pkgs/development/python-modules/glom/default.nix +++ b/pkgs/development/python-modules/glom/default.nix @@ -47,12 +47,13 @@ buildPythonPackage rec { ]; meta = with lib; { - homepage = "https://github.com/mahmoud/glom"; description = "Restructuring data, the Python way"; longDescription = '' glom helps pull together objects from other objects in a declarative, dynamic, and downright simple way. ''; + homepage = "https://github.com/mahmoud/glom"; + changelog = "https://github.com/mahmoud/glom/blob/v${version}/CHANGELOG.md"; license = licenses.bsd3; maintainers = with maintainers; [ twey ]; }; From f1e1feedac3673a27a3893693bf76f2d613931ea Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 19 Feb 2023 18:06:00 +0100 Subject: [PATCH 4/6] python311Packages.glom: disable failing tests on Python 3.11 --- pkgs/development/python-modules/glom/default.nix | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/glom/default.nix b/pkgs/development/python-modules/glom/default.nix index 41ae225293cf..876feaf6c2c6 100644 --- a/pkgs/development/python-modules/glom/default.nix +++ b/pkgs/development/python-modules/glom/default.nix @@ -1,12 +1,13 @@ { lib -, buildPythonPackage -, fetchPypi -, boltons , attrs +, boltons +, buildPythonPackage , face +, fetchPypi , pytestCheckHook -, pyyaml +, pythonAtLeast , pythonOlder +, pyyaml }: buildPythonPackage rec { @@ -40,6 +41,9 @@ buildPythonPackage rec { disabledTests = [ # Test is outdated (was made for PyYAML 3.x) "test_main_yaml_target" + ] ++ lib.optionals (pythonAtLeast "3.11") [ + "test_regular_error_stack" + "test_long_target_repr" ]; pythonImportsCheck = [ From fdfb7f360706f652e1c48433acb1ddfc12ddbaf2 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 19 Feb 2023 18:08:31 +0100 Subject: [PATCH 5/6] python310Packages.dinghy: add changelog to meta --- pkgs/development/python-modules/dinghy/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/dinghy/default.nix b/pkgs/development/python-modules/dinghy/default.nix index fa62731071b6..aea49cde6f18 100644 --- a/pkgs/development/python-modules/dinghy/default.nix +++ b/pkgs/development/python-modules/dinghy/default.nix @@ -22,7 +22,7 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "nedbat"; repo = pname; - rev = version; + rev = "refs/tags/${version}"; hash = "sha256-xtcNcykfgcWvifso0xaeMT31+G5x4HCp+tLAIEEq4cw="; }; @@ -47,6 +47,7 @@ buildPythonPackage rec { meta = with lib; { description = "A GitHub activity digest tool"; homepage = "https://github.com/nedbat/dinghy"; + changelog = "https://github.com/nedbat/dinghy/blob/${version}/CHANGELOG.rst"; license = licenses.asl20; maintainers = with maintainers; [ trundle veehaitch ]; }; From d4f730eea658d6aae88e6451d380bbd910b36ee3 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 19 Feb 2023 18:18:52 +0100 Subject: [PATCH 6/6] python311Packages.eliot: switch to pytestCheckHook --- .../python-modules/eliot/default.nix | 34 ++++++++++++------- 1 file changed, 21 insertions(+), 13 deletions(-) diff --git a/pkgs/development/python-modules/eliot/default.nix b/pkgs/development/python-modules/eliot/default.nix index 4797c1cb038b..1ddae0409fbb 100644 --- a/pkgs/development/python-modules/eliot/default.nix +++ b/pkgs/development/python-modules/eliot/default.nix @@ -6,7 +6,7 @@ , boltons , hypothesis , pyrsistent -, pytest +, pytestCheckHook , setuptools , six , testtools @@ -16,19 +16,15 @@ buildPythonPackage rec { pname = "eliot"; version = "1.14.0"; + format = "setuptools"; + disabled = pythonOlder "3.6"; src = fetchPypi { inherit pname version; - sha256 = "c2f099a3e8d5ecfc22745766e7cc664a48db64b6b89d986dff270491d8683149"; + hash = "sha256-wvCZo+jV7PwidFdm58xmSkjbZLa4nZht/ycEkdhoMUk="; }; - nativeCheckInputs = [ - hypothesis - testtools - pytest - ]; - propagatedBuildInputs = [ aiocontextvars boltons @@ -38,19 +34,31 @@ buildPythonPackage rec { zope_interface ]; - pythonImportsCheck = [ "eliot" ]; + nativeCheckInputs = [ + hypothesis + pytestCheckHook + testtools + ]; + + pythonImportsCheck = [ + "eliot" + ]; # Tests run eliot-prettyprint in out/bin. - # test_parse_stream is broken, skip it. - checkPhase = '' + preCheck = '' export PATH=$out/bin:$PATH - pytest -k 'not test_parse_stream' ''; + disabledTests = [ + "test_parse_stream" + # AttributeError: module 'inspect' has no attribute 'getargspec' + "test_default" + ]; + meta = with lib; { homepage = "https://eliot.readthedocs.io"; description = "Logging library that tells you why it happened"; license = licenses.asl20; - maintainers = [ maintainers.dpausp ]; + maintainers = with maintainers; [ dpausp ]; }; }