1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 graphql-core, 6 pytest-asyncio, 7 pytestCheckHook, 8 pythonOlder, 9}: 10 11buildPythonPackage rec { 12 pname = "apischema"; 13 version = "0.18.1"; 14 format = "setuptools"; 15 16 disabled = pythonOlder "3.7"; 17 18 src = fetchFromGitHub { 19 owner = "wyfo"; 20 repo = "apischema"; 21 rev = "refs/tags/v${version}"; 22 hash = "sha256-omw6znk09r2SigPfaVrtA6dd8KeSfjaPgGfK12ty23g="; 23 }; 24 25 passthru.optional-dependencies = { 26 graphql = [ graphql-core ]; 27 }; 28 29 nativeCheckInputs = [ 30 pytest-asyncio 31 pytestCheckHook 32 ] ++ lib.flatten (builtins.attrValues passthru.optional-dependencies); 33 34 pythonImportsCheck = [ "apischema" ]; 35 36 meta = with lib; { 37 description = "JSON (de)serialization, GraphQL and JSON schema generation using typing"; 38 homepage = "https://github.com/wyfo/apischema"; 39 license = licenses.mit; 40 maintainers = with maintainers; [ fab ]; 41 }; 42}