nixpkgs/pkgs/development/python-modules/graphene-django/default.nix
Martin Weinelt 704aec5b4a
python3Packages.graphene-django: 3.0.0b7 -> unstable-2021-06-11
Prevents test breakage with django_3.
2021-11-02 18:31:42 +01:00

66 lines
1.2 KiB
Nix

{ lib
, buildPythonPackage
, pythonOlder
, fetchFromGitHub
, graphene
, graphql-core
, django
, djangorestframework
, promise
, text-unidecode
, django-filter
, mock
, pytest-django
, pytest-random-order
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "graphene-django";
version = "unstable-2021-06-11";
format = "setuptools";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "graphql-python";
repo = pname;
rev = "e7f7d8da07ba1020f9916153f17e97b0ec037712";
sha256 = "0b33q1im90ahp3gzy9wx5amfzy6q57ydjpy5rn988gh81hbyqaxv";
};
postPatch = ''
substituteInPlace setup.py \
--replace '"pytest-runner"' ""
'';
propagatedBuildInputs = [
djangorestframework
graphene
graphql-core
django
promise
text-unidecode
];
preCheck = ''
export DJANGO_SETTINGS_MODULE=examples.django_test_settings
'';
checkInputs = [
django-filter
mock
pytest-django
pytest-random-order
pytestCheckHook
];
meta = with lib; {
description = "Integrate GraphQL into your Django project";
homepage = "https://github.com/graphql-python/graphene-django";
license = licenses.mit;
maintainers = with maintainers; [ hexa ];
};
}