Files
nixpkgs/pkgs/development/python-modules/ariadne/default.nix
T
Ihar Hrachyshka 567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

89 lines
2.2 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
freezegun,
graphql-core,
hatchling,
httpx,
pytest-asyncio,
pytest-mock,
pytestCheckHook,
python-multipart,
starlette,
syrupy,
typing-extensions,
werkzeug,
}:
buildPythonPackage rec {
pname = "ariadne";
version = "0.27.0";
pyproject = true;
src = fetchFromGitHub {
owner = "mirumee";
repo = "ariadne";
tag = version;
hash = "sha256-y09w1y+NV2HX8cXGMqv6LvPqGXxFfoaz4DS+oH25dNg=";
};
patches = [ ./remove-opentracing.patch ];
pythonRelaxDeps = [ "graphql-core" ];
build-system = [ hatchling ];
dependencies = [
graphql-core
starlette
typing-extensions
];
nativeCheckInputs = [
freezegun
httpx
pytest-asyncio
pytest-mock
pytestCheckHook
python-multipart
syrupy
werkzeug
];
pythonImportsCheck = [ "ariadne" ];
pytestFlags = [ "--snapshot-update" ];
disabledTests = [
# TypeError: TestClient.request() got an unexpected keyword argument 'content'
"test_attempt_parse_request_missing_content_type_raises_bad_request_error"
"test_attempt_parse_non_json_request_raises_bad_request_error"
"test_attempt_parse_non_json_request_body_raises_bad_request_error"
# opentracing
"test_query_is_executed_for_multipart_form_request_with_file"
"test_query_is_executed_for_multipart_request_with_large_file_with_tracing"
# AssertionError: assert not [GraphQLError(...
"test_enum_with_int_values_from_dict"
"test_enum_with_int_enum_values"
"test_enum_with_str_enum_values"
];
disabledTestPaths = [
# missing graphql-sync-dataloader test dep
"tests/test_dataloaders.py"
"tests/wsgi/test_configuration.py"
# both include opentracing module, which has been removed from nixpkgs
"tests/tracing/test_opentracing.py"
"tests/tracing/test_opentelemetry.py"
];
meta = {
description = "Python library for implementing GraphQL servers using schema-first approach";
homepage = "https://ariadnegraphql.org";
changelog = "https://github.com/mirumee/ariadne/blob/${src.tag}/CHANGELOG.md";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ samuela ];
};
}