From 9b6d860b3f5e234772cd05de7d06fba41efd6972 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Wed, 1 Jun 2022 22:18:33 +0200 Subject: [PATCH 1/2] python310Packages.graphene: 3.0.0 -> 3.1.0 --- .../python-modules/graphene/default.nix | 32 ++----------------- 1 file changed, 3 insertions(+), 29 deletions(-) diff --git a/pkgs/development/python-modules/graphene/default.nix b/pkgs/development/python-modules/graphene/default.nix index 7d44f4c6a245..926da5784b1a 100644 --- a/pkgs/development/python-modules/graphene/default.nix +++ b/pkgs/development/python-modules/graphene/default.nix @@ -1,7 +1,6 @@ { lib , aniso8601 , buildPythonPackage -, fetchpatch , fetchFromGitHub , graphql-core , graphql-relay @@ -18,32 +17,18 @@ buildPythonPackage rec { pname = "graphene"; - version = "3.0.0"; + version = "3.1.0"; format = "setuptools"; - disabled = pythonOlder "3.7"; + disabled = pythonOlder "3.6"; src = fetchFromGitHub { owner = "graphql-python"; repo = "graphene"; rev = "v${version}"; - sha256 = "0qgp3nl6afyz6y27bw175hyqppx75pp1vqwl7nvlpwvgwyyc2mnl"; + sha256 = "sha256-fKvaor9tOsJWXFMAH0/iDQi5NYJPec2sJevbQsKhQQ4="; }; - patches = [ - # Fix graphql-core 3.2.0 support - (fetchpatch { - # https://github.com/graphql-python/graphene/pull/1378 - url = "https://github.com/graphql-python/graphene/commit/989970f89341ebb949962d13dcabca8a6ccddad4.patch"; - hash = "sha256-qRxWTqv5XQN7uFjL2uv9NjTvSLi76/MyFSa4jpkb8to="; - }) - (fetchpatch { - # https://github.com/graphql-python/graphene/pull/1417 - url = "https://github.com/graphql-python/graphene/commit/4e0e18d1682b7759bdf16499c573f675c7fb51cb.patch"; - hash = "sha256-icdTGDabJouQ3hVpcMkkeabNwdoDxdVVAboTOWFbO94="; - }) - ]; - propagatedBuildInputs = [ aniso8601 graphql-core @@ -64,17 +49,6 @@ buildPythonPackage rec { "--benchmark-disable" ]; - disabledTests = [ - # Expects different Exeception classes, but receives none of them - # https://github.com/graphql-python/graphene/issues/1346 - "test_unexpected_error" - # https://github.com/graphql-python/graphene/pull/1417#issuecomment-1102492138 - "test_example_end_to_end" - ] ++ lib.optionals (pythonAtLeast "3.10") [ - "test_objecttype_as_container_extra_args" - "test_objecttype_as_container_invalid_kwargs" - ]; - pythonImportsCheck = [ "graphene" ]; From 8dd005558cd28db606b6b271e14bcf2b693b1eab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Sat, 4 Jun 2022 01:57:57 +0200 Subject: [PATCH 2/2] python310Packages.graphene-django: fix tests --- pkgs/development/python-modules/graphene-django/default.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkgs/development/python-modules/graphene-django/default.nix b/pkgs/development/python-modules/graphene-django/default.nix index 404a6779505b..f5d9b7904594 100644 --- a/pkgs/development/python-modules/graphene-django/default.nix +++ b/pkgs/development/python-modules/graphene-django/default.nix @@ -2,6 +2,7 @@ , buildPythonPackage , pythonOlder , fetchFromGitHub +, fetchpatch , graphene , graphql-core @@ -32,6 +33,11 @@ buildPythonPackage rec { patches = [ ./graphene-3_2_0.patch + (fetchpatch { + url = "https://github.com/graphql-python/graphene-django/commit/ca555293a4334c26cf9a390dd1e3d0bd4c819a17.patch"; + excludes = [ "setup.py" ]; + sha256 = "sha256-RxG1MRhmpBKnHhSg4SV+DjZ3uA0nl9oUeei56xjtUpw="; + }) ]; postPatch = ''