strawberry-graphql 0.224.2__tar.gz → 0.225.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/PKG-INFO +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/pyproject.toml +18 -4
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/aiohttp/handlers/graphql_transport_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/aiohttp/handlers/graphql_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/aiohttp/views.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/annotation.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/arguments.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/asgi/__init__.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/asgi/handlers/graphql_transport_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/asgi/handlers/graphql_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/asgi/test/client.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/auto.py +5 -5
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/chalice/views.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/handlers/base.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/handlers/graphql_transport_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/handlers/graphql_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/handlers/http_handler.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/handlers/ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/router.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/testing.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/query_codegen.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/custom_scalar.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/django/__init__.py +3 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/django/context.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/django/views.py +3 -3
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/__init__.py +12 -12
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/conflicting_arguments.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/duplicated_type_name.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/invalid_argument_type.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/missing_arguments_annotations.py +5 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/missing_field_annotation.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/missing_return_annotation.py +5 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/not_a_strawberry_enum.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/object_is_not_a_class.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/object_is_not_an_enum.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/permission_fail_silently_requires_optional.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/private_strawberry_field.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/scalar_already_registered.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/unresolved_field_type.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/_compat.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/conversion_types.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/exceptions.py +9 -4
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/ext/mypy_plugin.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/__init__.py +2 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/add_validation_rules.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/base_extension.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/context.py +10 -8
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/disable_validation.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/mask_errors.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/max_aliases.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/max_tokens.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/parser_cache.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/query_depth_limiter.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/runner.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/tracing/__init__.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/tracing/apollo.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/tracing/datadog.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/tracing/opentelemetry.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/tracing/sentry.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/validation_cache.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/fastapi/router.py +47 -5
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/schema.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/schema_directives.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/field.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/flask/views.py +3 -3
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/exceptions.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/lazy_type.py +16 -3
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/litestar/controller.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/litestar/handlers/graphql_transport_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/litestar/handlers/graphql_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/object_type.py +3 -3
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/permission.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/quart/views.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/relay/exceptions.py +3 -3
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/relay/types.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/sanic/views.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/config.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/exceptions.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/schema.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/schema_converter.py +7 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema_codegen/__init__.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/starlite/controller.py +6 -6
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/starlite/handlers/graphql_transport_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/starlite/handlers/graphql_ws_handler.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/subscriptions/protocols/graphql_transport_ws/handlers.py +14 -4
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/subscriptions/protocols/graphql_ws/handlers.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/test/client.py +6 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/type.py +3 -3
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/execution.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/fields/resolver.py +3 -3
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/types.py +1 -1
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/union.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/unset.py +2 -2
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/LICENSE +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/README.md +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/__main__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/aiohttp/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/aiohttp/handlers/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/aiohttp/test/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/aiohttp/test/client.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/asgi/handlers/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/asgi/test/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/chalice/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/app.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/commands/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/commands/codegen.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/commands/export_schema.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/commands/schema_codegen.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/commands/server.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/commands/upgrade/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/commands/upgrade/_fake_progress.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/commands/upgrade/_run_codemod.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/constants.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/debug_server.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/utils/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/cli/utils/load_schema.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/exceptions.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/plugins/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/plugins/print_operation.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/plugins/python.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/plugins/typescript.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/types.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codemods/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codemods/annotated_unions.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/dataloader.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/directive.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/django/apps.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/django/test/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/django/test/client.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/enum.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/exception.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/exception_source.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/invalid_union_type.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/syntax.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/utils/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/exceptions/utils/source_finder.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/conversion.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/error_type.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/fields.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/object_type.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/experimental/pydantic/utils.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/ext/LICENSE +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/ext/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/ext/dataclasses/LICENSE +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/ext/dataclasses/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/ext/dataclasses/dataclasses.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/directives.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/field_extension.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/pyinstrument.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/tracing/utils.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/extensions/utils.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/fastapi/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/fastapi/context.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/fastapi/handlers/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/fastapi/handlers/graphql_transport_ws_handler.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/fastapi/handlers/graphql_ws_handler.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/argument.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/enum.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/field.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/mutation.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/object_type.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/scalar.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/schema_directive.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/types.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/federation/union.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/field_extensions/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/field_extensions/input_mutation.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/file_uploads/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/file_uploads/scalars.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/file_uploads/utils.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/flask/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/async_base_view.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/base.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/ides.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/sync_base_view.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/temporal_response.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/types.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/http/typevars.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/litestar/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/mutation.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/parent.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/printer/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/printer/ast_from_value.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/printer/printer.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/private.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/py.typed +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/quart/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/relay/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/relay/fields.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/relay/utils.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/resolvers.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/sanic/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/sanic/context.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/sanic/utils.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/scalars.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/base.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/compat.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/execute.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/name_converter.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/types/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/types/base_scalars.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/types/concrete_type.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema/types/scalar.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/schema_directive.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/starlite/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/static/apollo-sandbox.html +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/static/graphiql.html +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/static/pathfinder.html +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/subscriptions/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/subscriptions/protocols/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/subscriptions/protocols/graphql_transport_ws/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/subscriptions/protocols/graphql_transport_ws/types.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/subscriptions/protocols/graphql_ws/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/subscriptions/protocols/graphql_ws/types.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/test/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/tools/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/tools/create_type.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/tools/merge_types.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/fields/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/graphql.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/info.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/nodes.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/types/type_resolver.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/__init__.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/aio.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/await_maybe.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/dataclasses.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/debug.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/deprecations.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/graphql_lexer.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/importer.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/inspect.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/logging.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/operation.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/str_converters.py +0 -0
- {strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/utils/typing.py +0 -0
@@ -1,7 +1,7 @@
|
|
1
1
|
[tool.poetry]
|
2
2
|
name = "strawberry-graphql"
|
3
3
|
packages = [ { include = "strawberry" } ]
|
4
|
-
version = "0.
|
4
|
+
version = "0.225.0"
|
5
5
|
description = "A library for creating GraphQL APIs"
|
6
6
|
authors = ["Patrick Arminio <patrick.arminio@gmail.com>"]
|
7
7
|
license = "MIT"
|
@@ -102,6 +102,7 @@ pytest-mypy-plugins = ">=1.10,<4.0"
|
|
102
102
|
poetry-plugin-export = "^1.6.0"
|
103
103
|
# another bug in poetry
|
104
104
|
urllib3 = "<2"
|
105
|
+
ruff = "^0.3.7"
|
105
106
|
|
106
107
|
[tool.poetry.group.integrations]
|
107
108
|
optional = true
|
@@ -239,8 +240,6 @@ ignore = [
|
|
239
240
|
# definitely enable these, maybe not in tests
|
240
241
|
"ANN102",
|
241
242
|
"ANN202",
|
242
|
-
"ANN204",
|
243
|
-
"ANN205",
|
244
243
|
"ANN401",
|
245
244
|
"PGH003",
|
246
245
|
"PGH004",
|
@@ -355,7 +354,22 @@ ignore = [
|
|
355
354
|
|
356
355
|
[tool.ruff.lint.per-file-ignores]
|
357
356
|
"strawberry/schema/types/concrete_type.py" = ["TCH002"]
|
358
|
-
"tests/*" = [
|
357
|
+
"tests/*" = [
|
358
|
+
"RSE102",
|
359
|
+
"SLF001",
|
360
|
+
"TCH001",
|
361
|
+
"TCH002",
|
362
|
+
"TCH003",
|
363
|
+
"ANN001",
|
364
|
+
"ANN201",
|
365
|
+
"ANN202",
|
366
|
+
"ANN204",
|
367
|
+
"PLW0603",
|
368
|
+
"PLC1901",
|
369
|
+
"S603",
|
370
|
+
"S607",
|
371
|
+
"B018",
|
372
|
+
]
|
359
373
|
"strawberry/extensions/tracing/__init__.py" = ["TCH004"]
|
360
374
|
"tests/http/clients/__init__.py" = ["F401"]
|
361
375
|
|
@@ -23,7 +23,7 @@ class GraphQLTransportWSHandler(BaseGraphQLTransportWSHandler):
|
|
23
23
|
get_context: Callable[..., Dict[str, Any]],
|
24
24
|
get_root_value: Any,
|
25
25
|
request: web.Request,
|
26
|
-
):
|
26
|
+
) -> None:
|
27
27
|
super().__init__(schema, debug, connection_init_wait_timeout)
|
28
28
|
self._get_context = get_context
|
29
29
|
self._get_root_value = get_root_value
|
@@ -22,7 +22,7 @@ class GraphQLWSHandler(BaseGraphQLWSHandler):
|
|
22
22
|
get_context: Callable,
|
23
23
|
get_root_value: Callable,
|
24
24
|
request: web.Request,
|
25
|
-
):
|
25
|
+
) -> None:
|
26
26
|
super().__init__(schema, debug, keep_alive, keep_alive_interval)
|
27
27
|
self._get_context = get_context
|
28
28
|
self._get_root_value = get_root_value
|
@@ -35,7 +35,7 @@ if TYPE_CHECKING:
|
|
35
35
|
|
36
36
|
|
37
37
|
class AioHTTPRequestAdapter(AsyncHTTPRequestAdapter):
|
38
|
-
def __init__(self, request: web.Request):
|
38
|
+
def __init__(self, request: web.Request) -> None:
|
39
39
|
self.request = request
|
40
40
|
|
41
41
|
@property
|
@@ -100,7 +100,7 @@ class GraphQLView(
|
|
100
100
|
GRAPHQL_WS_PROTOCOL,
|
101
101
|
),
|
102
102
|
connection_init_wait_timeout: timedelta = timedelta(minutes=1),
|
103
|
-
):
|
103
|
+
) -> None:
|
104
104
|
self.schema = schema
|
105
105
|
self.allow_queries_via_get = allow_queries_via_get
|
106
106
|
self.keep_alive = keep_alive
|
@@ -54,7 +54,7 @@ class StrawberryArgumentAnnotation:
|
|
54
54
|
deprecation_reason: Optional[str] = None,
|
55
55
|
directives: Iterable[object] = (),
|
56
56
|
metadata: Optional[Mapping[Any, Any]] = None,
|
57
|
-
):
|
57
|
+
) -> None:
|
58
58
|
self.description = description
|
59
59
|
self.name = name
|
60
60
|
self.deprecation_reason = deprecation_reason
|
@@ -117,7 +117,7 @@ class GraphQL(
|
|
117
117
|
else:
|
118
118
|
self.graphql_ide = graphql_ide
|
119
119
|
|
120
|
-
async def __call__(self, scope: Scope, receive: Receive, send: Send):
|
120
|
+
async def __call__(self, scope: Scope, receive: Receive, send: Send) -> None:
|
121
121
|
if scope["type"] == "http":
|
122
122
|
return await self.handle_http(scope, receive, send)
|
123
123
|
|
@@ -26,7 +26,7 @@ class GraphQLTransportWSHandler(BaseGraphQLTransportWSHandler):
|
|
26
26
|
get_context: Callable,
|
27
27
|
get_root_value: Callable,
|
28
28
|
ws: WebSocket,
|
29
|
-
):
|
29
|
+
) -> None:
|
30
30
|
super().__init__(schema, debug, connection_init_wait_timeout)
|
31
31
|
self._get_context = get_context
|
32
32
|
self._get_root_value = get_root_value
|
@@ -25,7 +25,7 @@ class GraphQLWSHandler(BaseGraphQLWSHandler):
|
|
25
25
|
get_context: Callable,
|
26
26
|
get_root_value: Callable,
|
27
27
|
ws: WebSocket,
|
28
|
-
):
|
28
|
+
) -> None:
|
29
29
|
super().__init__(schema, debug, keep_alive, keep_alive_interval)
|
30
30
|
self._get_context = get_context
|
31
31
|
self._get_root_value = get_root_value
|
@@ -24,11 +24,11 @@ class StrawberryAutoMeta(type):
|
|
24
24
|
|
25
25
|
"""
|
26
26
|
|
27
|
-
def __init__(self, *args: str, **kwargs: Any):
|
27
|
+
def __init__(self, *args: str, **kwargs: Any) -> None:
|
28
28
|
self._instance: Optional[StrawberryAuto] = None
|
29
29
|
super().__init__(*args, **kwargs)
|
30
30
|
|
31
|
-
def __call__(cls, *args: str, **kwargs: Any):
|
31
|
+
def __call__(cls, *args: str, **kwargs: Any) -> Any:
|
32
32
|
if cls._instance is None:
|
33
33
|
cls._instance = super().__call__(*args, **kwargs)
|
34
34
|
|
@@ -37,7 +37,7 @@ class StrawberryAutoMeta(type):
|
|
37
37
|
def __instancecheck__(
|
38
38
|
self,
|
39
39
|
instance: Union[StrawberryAuto, StrawberryAnnotation, StrawberryType, type],
|
40
|
-
):
|
40
|
+
) -> bool:
|
41
41
|
if isinstance(instance, StrawberryAnnotation):
|
42
42
|
resolved = instance.raw_annotation
|
43
43
|
if isinstance(resolved, str):
|
@@ -69,10 +69,10 @@ class StrawberryAutoMeta(type):
|
|
69
69
|
|
70
70
|
|
71
71
|
class StrawberryAuto(metaclass=StrawberryAutoMeta):
|
72
|
-
def __str__(self):
|
72
|
+
def __str__(self) -> str:
|
73
73
|
return "auto"
|
74
74
|
|
75
|
-
def __repr__(self):
|
75
|
+
def __repr__(self) -> str:
|
76
76
|
return "<auto>"
|
77
77
|
|
78
78
|
|
@@ -17,7 +17,7 @@ if TYPE_CHECKING:
|
|
17
17
|
|
18
18
|
|
19
19
|
class ChaliceHTTPRequestAdapter(SyncHTTPRequestAdapter):
|
20
|
-
def __init__(self, request: Request):
|
20
|
+
def __init__(self, request: Request) -> None:
|
21
21
|
self.request = request
|
22
22
|
|
23
23
|
@property
|
@@ -62,7 +62,7 @@ class GraphQLView(
|
|
62
62
|
graphiql: Optional[bool] = None,
|
63
63
|
graphql_ide: Optional[GraphQL_IDE] = "graphiql",
|
64
64
|
allow_queries_via_get: bool = True,
|
65
|
-
):
|
65
|
+
) -> None:
|
66
66
|
self.allow_queries_via_get = allow_queries_via_get
|
67
67
|
self.schema = schema
|
68
68
|
if graphiql is not None:
|
{strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/handlers/base.py
RENAMED
@@ -68,7 +68,7 @@ class ChannelsConsumer(AsyncConsumer):
|
|
68
68
|
channel_layer: Optional[ChannelsLayer]
|
69
69
|
channel_receive: Callable[[], Awaitable[dict]]
|
70
70
|
|
71
|
-
def __init__(self, *args: str, **kwargs: Any):
|
71
|
+
def __init__(self, *args: str, **kwargs: Any) -> None:
|
72
72
|
self.listen_queues: DefaultDict[str, WeakSet[asyncio.Queue]] = defaultdict(
|
73
73
|
WeakSet
|
74
74
|
)
|
@@ -23,7 +23,7 @@ class GraphQLTransportWSHandler(BaseGraphQLTransportWSHandler):
|
|
23
23
|
get_context: Callable,
|
24
24
|
get_root_value: Callable,
|
25
25
|
ws: ChannelsWSConsumer,
|
26
|
-
):
|
26
|
+
) -> None:
|
27
27
|
super().__init__(schema, debug, connection_init_wait_timeout)
|
28
28
|
self._get_context = get_context
|
29
29
|
self._get_root_value = get_root_value
|
@@ -22,7 +22,7 @@ class GraphQLWSHandler(BaseGraphQLWSHandler):
|
|
22
22
|
get_context: Callable,
|
23
23
|
get_root_value: Callable,
|
24
24
|
ws: ChannelsWSConsumer,
|
25
|
-
):
|
25
|
+
) -> None:
|
26
26
|
super().__init__(schema, debug, keep_alive, keep_alive_interval)
|
27
27
|
self._get_context = get_context
|
28
28
|
self._get_root_value = get_root_value
|
@@ -102,7 +102,7 @@ class ChannelsRequest:
|
|
102
102
|
|
103
103
|
|
104
104
|
class BaseChannelsRequestAdapter:
|
105
|
-
def __init__(self, request: ChannelsRequest):
|
105
|
+
def __init__(self, request: ChannelsRequest) -> None:
|
106
106
|
self.request = request
|
107
107
|
|
108
108
|
@property
|
@@ -156,7 +156,7 @@ class BaseGraphQLHTTPConsumer(ChannelsConsumer, AsyncHttpConsumer):
|
|
156
156
|
allow_queries_via_get: bool = True,
|
157
157
|
subscriptions_enabled: bool = True,
|
158
158
|
**kwargs: Any,
|
159
|
-
):
|
159
|
+
) -> None:
|
160
160
|
self.schema = schema
|
161
161
|
self.allow_queries_via_get = allow_queries_via_get
|
162
162
|
self.subscriptions_enabled = subscriptions_enabled
|
{strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/channels/handlers/ws_handler.py
RENAMED
@@ -54,7 +54,7 @@ class GraphQLWSConsumer(ChannelsWSConsumer):
|
|
54
54
|
GRAPHQL_WS_PROTOCOL,
|
55
55
|
),
|
56
56
|
connection_init_wait_timeout: Optional[datetime.timedelta] = None,
|
57
|
-
):
|
57
|
+
) -> None:
|
58
58
|
if connection_init_wait_timeout is None:
|
59
59
|
connection_init_wait_timeout = datetime.timedelta(minutes=1)
|
60
60
|
self.connection_init_wait_timeout = connection_init_wait_timeout
|
@@ -48,7 +48,7 @@ class GraphQLProtocolTypeRouter(ProtocolTypeRouter):
|
|
48
48
|
schema: BaseSchema,
|
49
49
|
django_application: Optional[str] = None,
|
50
50
|
url_pattern: str = "^graphql",
|
51
|
-
):
|
51
|
+
) -> None:
|
52
52
|
http_urls = [re_path(url_pattern, GraphQLHTTPConsumer.as_asgi(schema=schema))]
|
53
53
|
if django_application is not None:
|
54
54
|
http_urls.append(re_path("^", django_application))
|
{strawberry_graphql-0.224.2 → strawberry_graphql-0.225.0}/strawberry/codegen/query_codegen.py
RENAMED
@@ -152,7 +152,7 @@ class QueryCodegenPlugin:
|
|
152
152
|
|
153
153
|
|
154
154
|
class ConsolePlugin:
|
155
|
-
def __init__(self, output_dir: Path):
|
155
|
+
def __init__(self, output_dir: Path) -> None:
|
156
156
|
self.output_dir = output_dir
|
157
157
|
self.files_generated: List[Path] = []
|
158
158
|
|
@@ -305,7 +305,7 @@ class QueryCodegen:
|
|
305
305
|
schema: Schema,
|
306
306
|
plugins: List[QueryCodegenPlugin],
|
307
307
|
console_plugin: Optional[ConsolePlugin] = None,
|
308
|
-
):
|
308
|
+
) -> None:
|
309
309
|
self.schema = schema
|
310
310
|
self.plugin_manager = QueryCodegenPluginManager(plugins, console_plugin)
|
311
311
|
self.types: List[GraphQLType] = []
|
@@ -67,10 +67,10 @@ class ScalarDefinition(StrawberryType):
|
|
67
67
|
class ScalarWrapper:
|
68
68
|
_scalar_definition: ScalarDefinition
|
69
69
|
|
70
|
-
def __init__(self, wrap: Callable[[Any], Any]):
|
70
|
+
def __init__(self, wrap: Callable[[Any], Any]) -> None:
|
71
71
|
self.wrap = wrap
|
72
72
|
|
73
|
-
def __call__(self, *args: str, **kwargs: Any):
|
73
|
+
def __call__(self, *args: str, **kwargs: Any) -> Any:
|
74
74
|
return self.wrap(*args, **kwargs)
|
75
75
|
|
76
76
|
def __or__(self, other: Union[StrawberryType, type]) -> StrawberryType:
|
@@ -1,3 +1,5 @@
|
|
1
|
+
from typing import Any
|
2
|
+
|
1
3
|
try:
|
2
4
|
# import modules and objects from external strawberry-graphql-django
|
3
5
|
# package so that it can be used through strawberry.django namespace
|
@@ -5,7 +7,7 @@ try:
|
|
5
7
|
except ModuleNotFoundError:
|
6
8
|
import importlib
|
7
9
|
|
8
|
-
def __getattr__(name: str):
|
10
|
+
def __getattr__(name: str) -> Any:
|
9
11
|
# try to import submodule and raise exception only if it does not exist
|
10
12
|
import_symbol = f"{__name__}.{name}"
|
11
13
|
try:
|
@@ -12,7 +12,7 @@ class StrawberryDjangoContext:
|
|
12
12
|
request: HttpRequest
|
13
13
|
response: HttpResponse
|
14
14
|
|
15
|
-
def __getitem__(self, key: str):
|
15
|
+
def __getitem__(self, key: str) -> Any:
|
16
16
|
# __getitem__ override needed to avoid issues for who's
|
17
17
|
# using info.context["request"]
|
18
18
|
return super().__getattribute__(key)
|
@@ -62,7 +62,7 @@ class TemporalHttpResponse(JsonResponse):
|
|
62
62
|
|
63
63
|
|
64
64
|
class DjangoHTTPRequestAdapter(SyncHTTPRequestAdapter):
|
65
|
-
def __init__(self, request: HttpRequest):
|
65
|
+
def __init__(self, request: HttpRequest) -> None:
|
66
66
|
self.request = request
|
67
67
|
|
68
68
|
@property
|
@@ -97,7 +97,7 @@ class DjangoHTTPRequestAdapter(SyncHTTPRequestAdapter):
|
|
97
97
|
|
98
98
|
|
99
99
|
class AsyncDjangoHTTPRequestAdapter(AsyncHTTPRequestAdapter):
|
100
|
-
def __init__(self, request: HttpRequest):
|
100
|
+
def __init__(self, request: HttpRequest) -> None:
|
101
101
|
self.request = request
|
102
102
|
|
103
103
|
@property
|
@@ -140,7 +140,7 @@ class BaseView:
|
|
140
140
|
allow_queries_via_get: bool = True,
|
141
141
|
subscriptions_enabled: bool = False,
|
142
142
|
**kwargs: Any,
|
143
|
-
):
|
143
|
+
) -> None:
|
144
144
|
self.schema = schema
|
145
145
|
self.allow_queries_via_get = allow_queries_via_get
|
146
146
|
self.subscriptions_enabled = subscriptions_enabled
|
@@ -35,7 +35,7 @@ setup_exception_handler()
|
|
35
35
|
class WrongReturnTypeForUnion(Exception):
|
36
36
|
"""The Union type cannot be resolved because it's not a field"""
|
37
37
|
|
38
|
-
def __init__(self, field_name: str, result_type: str):
|
38
|
+
def __init__(self, field_name: str, result_type: str) -> None:
|
39
39
|
message = (
|
40
40
|
f'The type "{result_type}" cannot be resolved for the field "{field_name}" '
|
41
41
|
", are you using a strawberry.field?"
|
@@ -50,7 +50,7 @@ class UnallowedReturnTypeForUnion(Exception):
|
|
50
50
|
|
51
51
|
def __init__(
|
52
52
|
self, field_name: str, result_type: str, allowed_types: Set[GraphQLObjectType]
|
53
|
-
):
|
53
|
+
) -> None:
|
54
54
|
formatted_allowed_types = list(sorted(type_.name for type_ in allowed_types))
|
55
55
|
|
56
56
|
message = (
|
@@ -63,7 +63,7 @@ class UnallowedReturnTypeForUnion(Exception):
|
|
63
63
|
|
64
64
|
# TODO: this doesn't seem to be tested
|
65
65
|
class InvalidTypeInputForUnion(Exception):
|
66
|
-
def __init__(self, annotation: GraphQLInputObjectType):
|
66
|
+
def __init__(self, annotation: GraphQLInputObjectType) -> None:
|
67
67
|
message = f"Union for {annotation} is not supported because it is an Input type"
|
68
68
|
super().__init__(message)
|
69
69
|
|
@@ -72,14 +72,14 @@ class InvalidTypeInputForUnion(Exception):
|
|
72
72
|
class MissingTypesForGenericError(Exception):
|
73
73
|
"""Raised when a generic types was used without passing any type."""
|
74
74
|
|
75
|
-
def __init__(self, annotation: Union[StrawberryType, type]):
|
75
|
+
def __init__(self, annotation: Union[StrawberryType, type]) -> None:
|
76
76
|
message = f'The type "{annotation!r}" is generic, but no type has been passed'
|
77
77
|
|
78
78
|
super().__init__(message)
|
79
79
|
|
80
80
|
|
81
81
|
class UnsupportedTypeError(StrawberryException):
|
82
|
-
def __init__(self, annotation: Union[StrawberryType, type]):
|
82
|
+
def __init__(self, annotation: Union[StrawberryType, type]) -> None:
|
83
83
|
message = f"{annotation} conversion is not supported"
|
84
84
|
|
85
85
|
super().__init__(message)
|
@@ -90,7 +90,7 @@ class UnsupportedTypeError(StrawberryException):
|
|
90
90
|
|
91
91
|
|
92
92
|
class MultipleStrawberryArgumentsError(Exception):
|
93
|
-
def __init__(self, argument_name: str):
|
93
|
+
def __init__(self, argument_name: str) -> None:
|
94
94
|
message = (
|
95
95
|
f"Annotation for argument `{argument_name}` cannot have multiple "
|
96
96
|
f"`strawberry.argument`s"
|
@@ -100,7 +100,7 @@ class MultipleStrawberryArgumentsError(Exception):
|
|
100
100
|
|
101
101
|
|
102
102
|
class WrongNumberOfResultsReturned(Exception):
|
103
|
-
def __init__(self, expected: int, received: int):
|
103
|
+
def __init__(self, expected: int, received: int) -> None:
|
104
104
|
message = (
|
105
105
|
"Received wrong number of results in dataloader, "
|
106
106
|
f"expected: {expected}, received: {received}"
|
@@ -110,7 +110,7 @@ class WrongNumberOfResultsReturned(Exception):
|
|
110
110
|
|
111
111
|
|
112
112
|
class FieldWithResolverAndDefaultValueError(Exception):
|
113
|
-
def __init__(self, field_name: str, type_name: str):
|
113
|
+
def __init__(self, field_name: str, type_name: str) -> None:
|
114
114
|
message = (
|
115
115
|
f'Field "{field_name}" on type "{type_name}" cannot define a default '
|
116
116
|
"value and a resolver."
|
@@ -120,7 +120,7 @@ class FieldWithResolverAndDefaultValueError(Exception):
|
|
120
120
|
|
121
121
|
|
122
122
|
class FieldWithResolverAndDefaultFactoryError(Exception):
|
123
|
-
def __init__(self, field_name: str, type_name: str):
|
123
|
+
def __init__(self, field_name: str, type_name: str) -> None:
|
124
124
|
message = (
|
125
125
|
f'Field "{field_name}" on type "{type_name}" cannot define a '
|
126
126
|
"default_factory and a resolver."
|
@@ -130,14 +130,14 @@ class FieldWithResolverAndDefaultFactoryError(Exception):
|
|
130
130
|
|
131
131
|
|
132
132
|
class MissingQueryError(Exception):
|
133
|
-
def __init__(self):
|
133
|
+
def __init__(self) -> None:
|
134
134
|
message = 'Request data is missing a "query" value'
|
135
135
|
|
136
136
|
super().__init__(message)
|
137
137
|
|
138
138
|
|
139
139
|
class InvalidDefaultFactoryError(Exception):
|
140
|
-
def __init__(self):
|
140
|
+
def __init__(self) -> None:
|
141
141
|
message = "`default_factory` must be a callable that requires no arguments"
|
142
142
|
|
143
143
|
super().__init__(message)
|
@@ -146,7 +146,7 @@ class InvalidDefaultFactoryError(Exception):
|
|
146
146
|
class InvalidCustomContext(Exception):
|
147
147
|
"""Raised when a custom context object is of the wrong python type"""
|
148
148
|
|
149
|
-
def __init__(self):
|
149
|
+
def __init__(self) -> None:
|
150
150
|
message = (
|
151
151
|
"The custom context must be either a class "
|
152
152
|
"that inherits from BaseContext or a dictionary"
|
@@ -15,7 +15,11 @@ if TYPE_CHECKING:
|
|
15
15
|
class MissingArgumentsAnnotationsError(StrawberryException):
|
16
16
|
"""The field is missing the annotation for one or more arguments"""
|
17
17
|
|
18
|
-
def __init__(
|
18
|
+
def __init__(
|
19
|
+
self,
|
20
|
+
resolver: StrawberryResolver,
|
21
|
+
arguments: List[str],
|
22
|
+
) -> None:
|
19
23
|
self.missing_arguments = arguments
|
20
24
|
self.function = resolver.wrapped_func
|
21
25
|
self.argument_name = arguments[0]
|
@@ -15,7 +15,11 @@ if TYPE_CHECKING:
|
|
15
15
|
class MissingReturnAnnotationError(StrawberryException):
|
16
16
|
"""The field is missing the return annotation"""
|
17
17
|
|
18
|
-
def __init__(
|
18
|
+
def __init__(
|
19
|
+
self,
|
20
|
+
field_name: str,
|
21
|
+
resolver: StrawberryResolver,
|
22
|
+
) -> None:
|
19
23
|
self.function = resolver.wrapped_func
|
20
24
|
|
21
25
|
self.message = (
|
@@ -17,7 +17,7 @@ class ObjectIsNotClassError(StrawberryException):
|
|
17
17
|
INTERFACE = "interface"
|
18
18
|
TYPE = "type"
|
19
19
|
|
20
|
-
def __init__(self, obj: object, method_type: MethodType):
|
20
|
+
def __init__(self, obj: object, method_type: MethodType) -> None:
|
21
21
|
self.obj = obj
|
22
22
|
self.function = obj
|
23
23
|
|
@@ -13,7 +13,7 @@ if TYPE_CHECKING:
|
|
13
13
|
|
14
14
|
|
15
15
|
class ObjectIsNotAnEnumError(StrawberryException):
|
16
|
-
def __init__(self, cls: Type[Enum]):
|
16
|
+
def __init__(self, cls: Type[Enum]) -> None:
|
17
17
|
self.cls = cls
|
18
18
|
self.message = (
|
19
19
|
"strawberry.enum can only be used with subclasses of Enum. "
|
@@ -12,7 +12,7 @@ if TYPE_CHECKING:
|
|
12
12
|
|
13
13
|
|
14
14
|
class PermissionFailSilentlyRequiresOptionalError(StrawberryException):
|
15
|
-
def __init__(self, field: StrawberryField):
|
15
|
+
def __init__(self, field: StrawberryField) -> None:
|
16
16
|
self.field = field
|
17
17
|
self.message = (
|
18
18
|
"Cannot use fail_silently=True with a non-optional " "or non-list field"
|
@@ -19,7 +19,7 @@ class ScalarAlreadyRegisteredError(StrawberryException):
|
|
19
19
|
self,
|
20
20
|
scalar_definition: ScalarDefinition,
|
21
21
|
other_scalar_definition: ScalarDefinition,
|
22
|
-
):
|
22
|
+
) -> None:
|
23
23
|
self.scalar_definition = scalar_definition
|
24
24
|
|
25
25
|
scalar_name = scalar_definition.name
|