strawberry-graphql 0.263.1__tar.gz → 0.263.2__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.263.1 → strawberry_graphql-0.263.2}/PKG-INFO +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/pyproject.toml +6 -6
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/aiohttp/views.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/annotation.py +9 -6
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/asgi/__init__.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/chalice/views.py +2 -2
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/codegen.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/query_codegen.py +6 -6
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/django/views.py +2 -2
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/handler.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/conversion.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/error_type.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/object_type.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/ext/mypy_plugin.py +3 -3
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/fastapi/router.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/schema.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/flask/views.py +2 -2
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/async_base_view.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/litestar/controller.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/printer/printer.py +7 -7
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/quart/views.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/relay/exceptions.py +3 -2
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/relay/fields.py +7 -7
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/relay/types.py +31 -28
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/sanic/utils.py +2 -4
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/sanic/views.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/schema.py +16 -12
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/subscriptions/protocols/graphql_transport_ws/handlers.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/subscriptions/protocols/graphql_ws/handlers.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/arguments.py +5 -4
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/auto.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/field.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/fields/resolver.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/lazy_type.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/type_resolver.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/union.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/aio.py +20 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/operation.py +1 -1
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/typing.py +5 -5
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/LICENSE +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/README.md +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/__main__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/aiohttp/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/aiohttp/test/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/aiohttp/test/client.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/asgi/test/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/asgi/test/client.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/chalice/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/channels/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/channels/handlers/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/channels/handlers/base.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/channels/handlers/http_handler.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/channels/handlers/ws_handler.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/channels/router.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/channels/testing.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/app.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/export_schema.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/schema_codegen.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/server.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/upgrade/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/upgrade/_fake_progress.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/upgrade/_run_codemod.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/constants.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/debug_server.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/utils/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/utils/load_schema.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/exceptions.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/plugins/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/plugins/print_operation.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/plugins/python.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/plugins/typescript.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/types.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codemods/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codemods/annotated_unions.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codemods/update_imports.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/dataloader.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/directive.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/django/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/django/apps.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/django/context.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/django/test/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/django/test/client.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/conflicting_arguments.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/duplicated_type_name.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/exception.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/exception_source.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/invalid_argument_type.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/invalid_union_type.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/missing_arguments_annotations.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/missing_dependencies.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/missing_field_annotation.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/missing_return_annotation.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/object_is_not_a_class.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/object_is_not_an_enum.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/permission_fail_silently_requires_optional.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/private_strawberry_field.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/scalar_already_registered.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/syntax.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/unresolved_field_type.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/utils/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/exceptions/utils/source_finder.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/_compat.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/conversion_types.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/exceptions.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/fields.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/experimental/pydantic/utils.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/ext/LICENSE +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/ext/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/ext/dataclasses/LICENSE +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/ext/dataclasses/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/ext/dataclasses/dataclasses.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/add_validation_rules.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/base_extension.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/context.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/directives.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/disable_validation.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/field_extension.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/mask_errors.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/max_aliases.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/max_tokens.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/parser_cache.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/pyinstrument.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/query_depth_limiter.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/runner.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/tracing/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/tracing/apollo.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/tracing/datadog.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/tracing/opentelemetry.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/tracing/utils.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/utils.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/extensions/validation_cache.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/fastapi/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/fastapi/context.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/argument.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/enum.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/field.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/mutation.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/object_type.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/scalar.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/schema_directive.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/schema_directives.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/types.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/federation/union.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/field_extensions/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/field_extensions/input_mutation.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/file_uploads/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/file_uploads/scalars.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/file_uploads/utils.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/flask/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/base.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/exceptions.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/ides.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/parse_content_type.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/sync_base_view.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/temporal_response.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/types.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/typevars.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/litestar/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/parent.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/permission.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/printer/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/printer/ast_from_value.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/py.typed +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/quart/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/relay/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/relay/utils.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/resolvers.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/sanic/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/sanic/context.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/scalars.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/base.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/compat.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/config.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/exceptions.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/name_converter.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/schema_converter.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/types/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/types/base_scalars.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/types/concrete_type.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/types/scalar.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/validation_rules/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema/validation_rules/one_of.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema_codegen/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema_directive.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/schema_directives.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/static/apollo-sandbox.html +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/static/graphiql.html +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/static/pathfinder.html +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/subscriptions/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/subscriptions/protocols/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/subscriptions/protocols/graphql_transport_ws/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/subscriptions/protocols/graphql_transport_ws/types.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/subscriptions/protocols/graphql_ws/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/subscriptions/protocols/graphql_ws/types.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/test/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/test/client.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/tools/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/tools/create_type.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/tools/merge_types.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/base.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/cast.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/enum.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/execution.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/fields/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/graphql.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/info.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/mutation.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/nodes.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/object_type.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/private.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/scalar.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/types/unset.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/__init__.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/await_maybe.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/dataclasses.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/debug.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/deprecations.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/graphql_lexer.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/importer.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/inspect.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/logging.py +0 -0
- {strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/utils/str_converters.py +0 -0
@@ -1,7 +1,7 @@
|
|
1
1
|
[tool.poetry]
|
2
2
|
name = "strawberry-graphql"
|
3
3
|
packages = [ { include = "strawberry" } ]
|
4
|
-
version = "0.263.
|
4
|
+
version = "0.263.2"
|
5
5
|
description = "A library for creating GraphQL APIs"
|
6
6
|
authors = ["Patrick Arminio <patrick.arminio@gmail.com>"]
|
7
7
|
license = "MIT"
|
@@ -56,7 +56,7 @@ rich = {version = ">=12.0.0", optional = true}
|
|
56
56
|
pyinstrument = {version = ">=4.0.0", optional = true}
|
57
57
|
|
58
58
|
[tool.poetry.group.dev.dependencies]
|
59
|
-
ruff = "^0.11.
|
59
|
+
ruff = "^0.11.4"
|
60
60
|
asgiref = "^3.2"
|
61
61
|
email-validator = {version = ">=1.1.3,<3.0.0", optional = false}
|
62
62
|
freezegun = "^1.2.1"
|
@@ -80,22 +80,22 @@ python-multipart = ">=0.0.7"
|
|
80
80
|
rich = {version = ">=12.5.1", optional = false}
|
81
81
|
sanic-testing = ">=22.9,<24.0"
|
82
82
|
typer = {version = ">=0.7.0", optional = false}
|
83
|
-
types-aiofiles = "
|
83
|
+
types-aiofiles = "^24.1.0.20250326"
|
84
84
|
types-certifi = "^2021.10.8"
|
85
85
|
types-chardet = "^5.0.4"
|
86
86
|
types-freezegun = "^1.1.9"
|
87
87
|
types-python-dateutil = "^2.8.19"
|
88
88
|
types-toml = "^0.10.8"
|
89
89
|
types-typed-ast = "^1.5.8"
|
90
|
-
types-ujson = "^5.
|
91
|
-
types-protobuf = "^
|
90
|
+
types-ujson = "^5.10.0.20250326"
|
91
|
+
types-protobuf = "^5.29.1.20250403"
|
92
92
|
poetry-plugin-export = {version = "^1.6.0", python = "<4.0", optional = false}
|
93
93
|
# another bug in poetry
|
94
94
|
urllib3 = "<2"
|
95
95
|
graphlib_backport = {version = "*", python = "<3.9", optional = false}
|
96
96
|
inline-snapshot = "^0.10.1"
|
97
97
|
types-deprecated = "^1.2.15.20241117"
|
98
|
-
types-six = "^1.17.0.
|
98
|
+
types-six = "^1.17.0.20250403"
|
99
99
|
types-pyyaml = "^6.0.12.20240917"
|
100
100
|
mypy = "^1.15.0"
|
101
101
|
codeflash = ">=0.9.2"
|
@@ -56,7 +56,7 @@ class AioHTTPRequestAdapter(AsyncHTTPRequestAdapter):
|
|
56
56
|
|
57
57
|
@property
|
58
58
|
def method(self) -> HTTPMethod:
|
59
|
-
return cast(HTTPMethod, self.request.method.upper())
|
59
|
+
return cast("HTTPMethod", self.request.method.upper())
|
60
60
|
|
61
61
|
@property
|
62
62
|
def headers(self) -> Mapping[str, str]:
|
@@ -1,8 +1,8 @@
|
|
1
1
|
from __future__ import annotations
|
2
2
|
|
3
|
-
import logging
|
4
3
|
import sys
|
5
4
|
import typing
|
5
|
+
import warnings
|
6
6
|
from collections import abc
|
7
7
|
from enum import Enum
|
8
8
|
from typing import (
|
@@ -130,7 +130,7 @@ class StrawberryAnnotation:
|
|
130
130
|
return self.__resolve_cache__
|
131
131
|
|
132
132
|
def _resolve(self) -> Union[StrawberryType, type]:
|
133
|
-
evaled_type = cast(Any, self.evaluate())
|
133
|
+
evaled_type = cast("Any", self.evaluate())
|
134
134
|
|
135
135
|
if is_private(evaled_type):
|
136
136
|
return evaled_type
|
@@ -158,7 +158,7 @@ class StrawberryAnnotation:
|
|
158
158
|
if self._is_union(evaled_type, args):
|
159
159
|
return self.create_union(evaled_type, args)
|
160
160
|
if is_type_var(evaled_type) or evaled_type is Self:
|
161
|
-
return self.create_type_var(cast(TypeVar, evaled_type))
|
161
|
+
return self.create_type_var(cast("TypeVar", evaled_type))
|
162
162
|
if self._is_strawberry_type(evaled_type):
|
163
163
|
# Simply return objects that are already StrawberryTypes
|
164
164
|
return evaled_type
|
@@ -242,9 +242,12 @@ class StrawberryAnnotation:
|
|
242
242
|
|
243
243
|
union_args = [arg for arg in args if isinstance(arg, StrawberryUnion)]
|
244
244
|
if len(union_args) > 1:
|
245
|
-
|
246
|
-
|
247
|
-
|
245
|
+
warnings.warn(
|
246
|
+
(
|
247
|
+
"Duplicate union definition detected. "
|
248
|
+
"Only the first definition will be considered"
|
249
|
+
),
|
250
|
+
stacklevel=2,
|
248
251
|
)
|
249
252
|
|
250
253
|
if union_args:
|
@@ -60,7 +60,7 @@ class ASGIRequestAdapter(AsyncHTTPRequestAdapter):
|
|
60
60
|
|
61
61
|
@property
|
62
62
|
def method(self) -> HTTPMethod:
|
63
|
-
return cast(HTTPMethod, self.request.method.upper())
|
63
|
+
return cast("HTTPMethod", self.request.method.upper())
|
64
64
|
|
65
65
|
@property
|
66
66
|
def headers(self) -> Mapping[str, str]:
|
@@ -7,7 +7,6 @@ from chalice.app import Request, Response
|
|
7
7
|
from strawberry.http.exceptions import HTTPException
|
8
8
|
from strawberry.http.sync_base_view import SyncBaseHTTPView, SyncHTTPRequestAdapter
|
9
9
|
from strawberry.http.temporal_response import TemporalResponse
|
10
|
-
from strawberry.http.types import HTTPMethod, QueryParams
|
11
10
|
from strawberry.http.typevars import Context, RootValue
|
12
11
|
|
13
12
|
if TYPE_CHECKING:
|
@@ -15,6 +14,7 @@ if TYPE_CHECKING:
|
|
15
14
|
|
16
15
|
from strawberry.http import GraphQLHTTPResponse
|
17
16
|
from strawberry.http.ides import GraphQL_IDE
|
17
|
+
from strawberry.http.types import HTTPMethod, QueryParams
|
18
18
|
from strawberry.schema import BaseSchema
|
19
19
|
|
20
20
|
|
@@ -32,7 +32,7 @@ class ChaliceHTTPRequestAdapter(SyncHTTPRequestAdapter):
|
|
32
32
|
|
33
33
|
@property
|
34
34
|
def method(self) -> HTTPMethod:
|
35
|
-
return cast(HTTPMethod, self.request.method.upper())
|
35
|
+
return cast("HTTPMethod", self.request.method.upper())
|
36
36
|
|
37
37
|
@property
|
38
38
|
def headers(self) -> Mapping[str, str]:
|
{strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/cli/commands/codegen.py
RENAMED
@@ -133,7 +133,7 @@ def codegen(
|
|
133
133
|
console_plugin.before_any_start()
|
134
134
|
|
135
135
|
for q in query:
|
136
|
-
plugins = cast(list[QueryCodegenPlugin], _load_plugins(selected_plugins, q))
|
136
|
+
plugins = cast("list[QueryCodegenPlugin]", _load_plugins(selected_plugins, q))
|
137
137
|
|
138
138
|
code_generator = QueryCodegen(
|
139
139
|
schema_symbol, plugins=plugins, console_plugin=console_plugin
|
{strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/codegen/query_codegen.py
RENAMED
@@ -362,7 +362,7 @@ class QueryCodegen:
|
|
362
362
|
# The FragmentDefinitionNode has a non-Optional `SelectionSetNode` but
|
363
363
|
# the Protocol wants an `Optional[SelectionSetNode]` so this doesn't
|
364
364
|
# quite conform.
|
365
|
-
cast(HasSelectionSet, fd),
|
365
|
+
cast("HasSelectionSet", fd),
|
366
366
|
parent_type=query_type,
|
367
367
|
class_name=fd.name.value,
|
368
368
|
graph_ql_object_type_factory=graph_ql_object_type_factory,
|
@@ -468,13 +468,13 @@ class QueryCodegen:
|
|
468
468
|
result_class_name = f"{operation_name}Result"
|
469
469
|
|
470
470
|
operation_type = self._collect_types(
|
471
|
-
cast(HasSelectionSet, operation_definition),
|
471
|
+
cast("HasSelectionSet", operation_definition),
|
472
472
|
parent_type=query_type,
|
473
473
|
class_name=result_class_name,
|
474
474
|
)
|
475
475
|
|
476
476
|
operation_kind = cast(
|
477
|
-
Literal[
|
477
|
+
"Literal['query', 'mutation', 'subscription']",
|
478
478
|
operation_definition.operation.value,
|
479
479
|
)
|
480
480
|
|
@@ -801,7 +801,7 @@ class QueryCodegen:
|
|
801
801
|
# `GraphQLField` or `GraphQLFragmentSpread`
|
802
802
|
# and the suite above will cause this statement to be
|
803
803
|
# skipped if there are any `GraphQLFragmentSpread`.
|
804
|
-
current_type.fields = cast(list[GraphQLField], fields)
|
804
|
+
current_type.fields = cast("list[GraphQLField]", fields)
|
805
805
|
|
806
806
|
self._collect_type(current_type)
|
807
807
|
|
@@ -854,7 +854,7 @@ class QueryCodegen:
|
|
854
854
|
assert isinstance(sub_selection, FieldNode)
|
855
855
|
|
856
856
|
parent_type = cast(
|
857
|
-
StrawberryObjectDefinition,
|
857
|
+
"StrawberryObjectDefinition",
|
858
858
|
self.schema.get_type_by_name(type_condition_name),
|
859
859
|
)
|
860
860
|
|
@@ -889,7 +889,7 @@ class QueryCodegen:
|
|
889
889
|
# `GraphQLField` or `GraphQLFragmentSpread`
|
890
890
|
# and the suite above will cause this statement to be
|
891
891
|
# skipped if there are any `GraphQLFragmentSpread`.
|
892
|
-
current_type.fields.extend(cast(list[GraphQLField], fields))
|
892
|
+
current_type.fields.extend(cast("list[GraphQLField]", fields))
|
893
893
|
|
894
894
|
sub_types.append(current_type)
|
895
895
|
|
@@ -83,7 +83,7 @@ class DjangoHTTPRequestAdapter(SyncHTTPRequestAdapter):
|
|
83
83
|
def method(self) -> HTTPMethod:
|
84
84
|
assert self.request.method is not None
|
85
85
|
|
86
|
-
return cast(HTTPMethod, self.request.method.upper())
|
86
|
+
return cast("HTTPMethod", self.request.method.upper())
|
87
87
|
|
88
88
|
@property
|
89
89
|
def headers(self) -> Mapping[str, str]:
|
@@ -114,7 +114,7 @@ class AsyncDjangoHTTPRequestAdapter(AsyncHTTPRequestAdapter):
|
|
114
114
|
def method(self) -> HTTPMethod:
|
115
115
|
assert self.request.method is not None
|
116
116
|
|
117
|
-
return cast(HTTPMethod, self.request.method.upper())
|
117
|
+
return cast("HTTPMethod", self.request.method.upper())
|
118
118
|
|
119
119
|
@property
|
120
120
|
def headers(self) -> Mapping[str, str]:
|
@@ -70,7 +70,7 @@ def strawberry_threading_exception_handler(
|
|
70
70
|
# (we'd need to do type ignore for python 3.8 and above, but mypy
|
71
71
|
# doesn't seem to be able to handle that and will complain in python 3.7)
|
72
72
|
|
73
|
-
cast(Any, original_threading_exception_hook)(args)
|
73
|
+
cast("Any", original_threading_exception_hook)(args)
|
74
74
|
|
75
75
|
return
|
76
76
|
|
@@ -35,7 +35,7 @@ def _convert_from_pydantic_to_strawberry_type(
|
|
35
35
|
if hasattr(option_type, "_pydantic_type"):
|
36
36
|
source_type = option_type._pydantic_type
|
37
37
|
else:
|
38
|
-
source_type = cast(type, option_type)
|
38
|
+
source_type = cast("type", option_type)
|
39
39
|
if isinstance(data, source_type):
|
40
40
|
return _convert_from_pydantic_to_strawberry_type(
|
41
41
|
option_type, data_from_model=data, extra=extra
|
@@ -116,7 +116,7 @@ def error_type(
|
|
116
116
|
]
|
117
117
|
|
118
118
|
wrapped: type[WithStrawberryObjectDefinition] = _wrap_dataclass(cls)
|
119
|
-
extra_fields = cast(list[dataclasses.Field], _get_fields(wrapped, {}))
|
119
|
+
extra_fields = cast("list[dataclasses.Field]", _get_fields(wrapped, {}))
|
120
120
|
private_fields = get_private_fields(wrapped)
|
121
121
|
|
122
122
|
all_model_fields.extend(
|
@@ -180,7 +180,7 @@ def type( # noqa: PLR0915
|
|
180
180
|
|
181
181
|
wrapped = _wrap_dataclass(cls)
|
182
182
|
extra_strawberry_fields = _get_fields(wrapped, {})
|
183
|
-
extra_fields = cast(list[dataclasses.Field], extra_strawberry_fields)
|
183
|
+
extra_fields = cast("list[dataclasses.Field]", extra_strawberry_fields)
|
184
184
|
private_fields = get_private_fields(wrapped)
|
185
185
|
|
186
186
|
extra_fields_dict = {field.name: field for field in extra_strawberry_fields}
|
@@ -65,7 +65,7 @@ try:
|
|
65
65
|
from pydantic.mypy import METADATA_KEY as PYDANTIC_METADATA_KEY
|
66
66
|
from pydantic.mypy import PydanticModelField
|
67
67
|
|
68
|
-
PYDANTIC_VERSION = tuple(map(int, pydantic.__version__.split(".")))
|
68
|
+
PYDANTIC_VERSION = tuple(map(int, pydantic.__version__.split("."))) # noqa: RUF048
|
69
69
|
|
70
70
|
from strawberry.experimental.pydantic._compat import IS_PYDANTIC_V1
|
71
71
|
except ImportError:
|
@@ -397,7 +397,7 @@ def strawberry_pydantic_class_callback(ctx: ClassDefContext) -> None:
|
|
397
397
|
]
|
398
398
|
add_method(ctx, "__init__", init_args, NoneType())
|
399
399
|
|
400
|
-
model_type = cast(Instance, _get_type_for_expr(model_expression, ctx.api))
|
400
|
+
model_type = cast("Instance", _get_type_for_expr(model_expression, ctx.api))
|
401
401
|
|
402
402
|
# these are the fields that the user added to the strawberry type
|
403
403
|
new_strawberry_fields: set[str] = set()
|
@@ -405,7 +405,7 @@ def strawberry_pydantic_class_callback(ctx: ClassDefContext) -> None:
|
|
405
405
|
# TODO: think about inheritance for strawberry?
|
406
406
|
for stmt in ctx.cls.defs.body:
|
407
407
|
if isinstance(stmt, AssignmentStmt):
|
408
|
-
lhs = cast(NameExpr, stmt.lvalues[0])
|
408
|
+
lhs = cast("NameExpr", stmt.lvalues[0])
|
409
409
|
new_strawberry_fields.add(lhs.name)
|
410
410
|
|
411
411
|
pydantic_fields: set[PydanticModelField] = set()
|
@@ -76,7 +76,7 @@ class GraphQLRouter(
|
|
76
76
|
connection: HTTPConnection,
|
77
77
|
response: Response = None, # type: ignore
|
78
78
|
) -> MergedContext:
|
79
|
-
request = cast(Union[Request, WebSocket], connection)
|
79
|
+
request = cast("Union[Request, WebSocket]", connection)
|
80
80
|
if isinstance(custom_context, BaseContext):
|
81
81
|
custom_context.request = request
|
82
82
|
custom_context.background_tasks = background_tasks
|
@@ -158,7 +158,7 @@ class Schema(BaseSchema):
|
|
158
158
|
type_name = representation.pop("__typename")
|
159
159
|
type_ = self.schema_converter.type_map[type_name]
|
160
160
|
|
161
|
-
definition = cast(StrawberryObjectDefinition, type_.definition)
|
161
|
+
definition = cast("StrawberryObjectDefinition", type_.definition)
|
162
162
|
|
163
163
|
if hasattr(definition.origin, "resolve_reference"):
|
164
164
|
resolve_reference = definition.origin.resolve_reference
|
@@ -45,7 +45,7 @@ class FlaskHTTPRequestAdapter(SyncHTTPRequestAdapter):
|
|
45
45
|
|
46
46
|
@property
|
47
47
|
def method(self) -> HTTPMethod:
|
48
|
-
return cast(HTTPMethod, self.request.method.upper())
|
48
|
+
return cast("HTTPMethod", self.request.method.upper())
|
49
49
|
|
50
50
|
@property
|
51
51
|
def headers(self) -> Mapping[str, str]:
|
@@ -139,7 +139,7 @@ class AsyncFlaskHTTPRequestAdapter(AsyncHTTPRequestAdapter):
|
|
139
139
|
|
140
140
|
@property
|
141
141
|
def method(self) -> HTTPMethod:
|
142
|
-
return cast(HTTPMethod, self.request.method.upper())
|
142
|
+
return cast("HTTPMethod", self.request.method.upper())
|
143
143
|
|
144
144
|
@property
|
145
145
|
def content_type(self) -> Optional[str]:
|
{strawberry_graphql-0.263.1 → strawberry_graphql-0.263.2}/strawberry/http/async_base_view.py
RENAMED
@@ -306,7 +306,7 @@ class AsyncBaseHTTPView(
|
|
306
306
|
await websocket.close(4406, "Subprotocol not acceptable")
|
307
307
|
|
308
308
|
return websocket_response
|
309
|
-
request = cast(Request, request)
|
309
|
+
request = cast("Request", request)
|
310
310
|
|
311
311
|
request_adapter = self.request_adapter_class(request)
|
312
312
|
sub_response = await self.get_sub_response(request)
|
@@ -163,7 +163,7 @@ class LitestarRequestAdapter(AsyncHTTPRequestAdapter):
|
|
163
163
|
|
164
164
|
@property
|
165
165
|
def method(self) -> HTTPMethod:
|
166
|
-
return cast(HTTPMethod, self.request.method.upper())
|
166
|
+
return cast("HTTPMethod", self.request.method.upper())
|
167
167
|
|
168
168
|
@property
|
169
169
|
def headers(self) -> Mapping[str, str]:
|
@@ -151,7 +151,7 @@ def print_schema_directive(
|
|
151
151
|
directive: Any, schema: BaseSchema, *, extras: PrintExtras
|
152
152
|
) -> str:
|
153
153
|
strawberry_directive = cast(
|
154
|
-
StrawberrySchemaDirective, directive.__class__.__strawberry_directive__
|
154
|
+
"StrawberrySchemaDirective", directive.__class__.__strawberry_directive__
|
155
155
|
)
|
156
156
|
schema_converter = schema.schema_converter
|
157
157
|
gql_directive = schema_converter.from_schema_directive(directive.__class__)
|
@@ -178,13 +178,13 @@ def print_schema_directive(
|
|
178
178
|
f_type = f_type.of_type
|
179
179
|
|
180
180
|
if has_object_definition(f_type):
|
181
|
-
extras.types.add(cast(type, f_type))
|
181
|
+
extras.types.add(cast("type", f_type))
|
182
182
|
|
183
183
|
if hasattr(f_type, "_scalar_definition"):
|
184
|
-
extras.types.add(cast(type, f_type))
|
184
|
+
extras.types.add(cast("type", f_type))
|
185
185
|
|
186
186
|
if isinstance(f_type, EnumDefinition):
|
187
|
-
extras.types.add(cast(type, f_type))
|
187
|
+
extras.types.add(cast("type", f_type))
|
188
188
|
|
189
189
|
return f" @{gql_directive.name}{params}"
|
190
190
|
|
@@ -363,7 +363,7 @@ def print_extends(type_: GraphQLObjectType, schema: BaseSchema) -> str:
|
|
363
363
|
from strawberry.schema.schema_converter import GraphQLCoreConverter
|
364
364
|
|
365
365
|
strawberry_type = cast(
|
366
|
-
Optional[StrawberryObjectDefinition],
|
366
|
+
"Optional[StrawberryObjectDefinition]",
|
367
367
|
type_.extensions
|
368
368
|
and type_.extensions.get(GraphQLCoreConverter.DEFINITION_BACKREF),
|
369
369
|
)
|
@@ -380,7 +380,7 @@ def print_type_directives(
|
|
380
380
|
from strawberry.schema.schema_converter import GraphQLCoreConverter
|
381
381
|
|
382
382
|
strawberry_type = cast(
|
383
|
-
Optional[StrawberryObjectDefinition],
|
383
|
+
"Optional[StrawberryObjectDefinition]",
|
384
384
|
type_.extensions
|
385
385
|
and type_.extensions.get(GraphQLCoreConverter.DEFINITION_BACKREF),
|
386
386
|
)
|
@@ -594,7 +594,7 @@ def is_builtin_directive(directive: GraphQLDirective) -> bool:
|
|
594
594
|
|
595
595
|
def print_schema(schema: BaseSchema) -> str:
|
596
596
|
graphql_core_schema = cast(
|
597
|
-
GraphQLSchema,
|
597
|
+
"GraphQLSchema",
|
598
598
|
schema._schema, # type: ignore
|
599
599
|
)
|
600
600
|
extras = PrintExtras()
|
@@ -27,7 +27,7 @@ class QuartHTTPRequestAdapter(AsyncHTTPRequestAdapter):
|
|
27
27
|
|
28
28
|
@property
|
29
29
|
def method(self) -> HTTPMethod:
|
30
|
-
return cast(HTTPMethod, self.request.method.upper())
|
30
|
+
return cast("HTTPMethod", self.request.method.upper())
|
31
31
|
|
32
32
|
@property
|
33
33
|
def content_type(self) -> Optional[str]:
|
@@ -1,6 +1,5 @@
|
|
1
1
|
from __future__ import annotations
|
2
2
|
|
3
|
-
from collections.abc import Callable
|
4
3
|
from functools import cached_property
|
5
4
|
from typing import TYPE_CHECKING, Optional, cast
|
6
5
|
|
@@ -8,6 +7,8 @@ from strawberry.exceptions.exception import StrawberryException
|
|
8
7
|
from strawberry.exceptions.utils.source_finder import SourceFinder
|
9
8
|
|
10
9
|
if TYPE_CHECKING:
|
10
|
+
from collections.abc import Callable
|
11
|
+
|
11
12
|
from strawberry.exceptions.exception_source import ExceptionSource
|
12
13
|
from strawberry.types.fields.resolver import StrawberryResolver
|
13
14
|
|
@@ -101,7 +102,7 @@ class RelayWrongResolverAnnotationError(StrawberryException):
|
|
101
102
|
return None # pragma: no cover
|
102
103
|
|
103
104
|
source_finder = SourceFinder()
|
104
|
-
return source_finder.find_function_from_object(cast(Callable, self.function))
|
105
|
+
return source_finder.find_function_from_object(cast("Callable", self.function))
|
105
106
|
|
106
107
|
|
107
108
|
__all__ = [
|
@@ -108,7 +108,7 @@ class NodeExtension(FieldExtension):
|
|
108
108
|
|
109
109
|
return resolve()
|
110
110
|
|
111
|
-
return cast(Node, strawberry_cast(node_type, resolved_node))
|
111
|
+
return cast("Node", strawberry_cast(node_type, resolved_node))
|
112
112
|
|
113
113
|
return resolver
|
114
114
|
|
@@ -161,7 +161,7 @@ class NodeExtension(FieldExtension):
|
|
161
161
|
# we could end up resolving to a different type in case more than one
|
162
162
|
# are registered
|
163
163
|
def cast_nodes(node_t: type[Node], nodes: Iterable[Any]) -> list[Node]:
|
164
|
-
return [cast(Node, strawberry_cast(node_t, node)) for node in nodes]
|
164
|
+
return [cast("Node", strawberry_cast(node_t, node)) for node in nodes]
|
165
165
|
|
166
166
|
if awaitable_nodes or asyncgen_nodes:
|
167
167
|
|
@@ -196,7 +196,7 @@ class NodeExtension(FieldExtension):
|
|
196
196
|
|
197
197
|
# Resolve any generator to lists
|
198
198
|
resolved = {
|
199
|
-
node_t: cast_nodes(node_t, cast(Iterable[Node], nodes))
|
199
|
+
node_t: cast_nodes(node_t, cast("Iterable[Node]", nodes))
|
200
200
|
for node_t, nodes in resolved_nodes.items()
|
201
201
|
}
|
202
202
|
return [resolved[index_map[gid][0]][index_map[gid][1]] for gid in ids]
|
@@ -264,7 +264,7 @@ class ConnectionExtension(FieldExtension):
|
|
264
264
|
type_origin = get_origin(f_type) if is_generic_alias(f_type) else f_type
|
265
265
|
|
266
266
|
if not isinstance(type_origin, type) or not issubclass(type_origin, Connection):
|
267
|
-
raise RelayWrongAnnotationError(field.name, cast(type, field.origin))
|
267
|
+
raise RelayWrongAnnotationError(field.name, cast("type", field.origin))
|
268
268
|
|
269
269
|
assert field.base_resolver
|
270
270
|
# TODO: We are not using resolver_type.type because it will call
|
@@ -294,7 +294,7 @@ class ConnectionExtension(FieldExtension):
|
|
294
294
|
):
|
295
295
|
raise RelayWrongResolverAnnotationError(field.name, field.base_resolver)
|
296
296
|
|
297
|
-
self.connection_type = cast(type[Connection[Node]], f_type)
|
297
|
+
self.connection_type = cast("type[Connection[Node]]", f_type)
|
298
298
|
|
299
299
|
def resolve(
|
300
300
|
self,
|
@@ -310,7 +310,7 @@ class ConnectionExtension(FieldExtension):
|
|
310
310
|
) -> Any:
|
311
311
|
assert self.connection_type is not None
|
312
312
|
return self.connection_type.resolve_connection(
|
313
|
-
cast(Iterable[Node], next_(source, info, **kwargs)),
|
313
|
+
cast("Iterable[Node]", next_(source, info, **kwargs)),
|
314
314
|
info=info,
|
315
315
|
before=before,
|
316
316
|
after=after,
|
@@ -339,7 +339,7 @@ class ConnectionExtension(FieldExtension):
|
|
339
339
|
nodes = await nodes
|
340
340
|
|
341
341
|
resolved = self.connection_type.resolve_connection(
|
342
|
-
cast(Iterable[Node], nodes),
|
342
|
+
cast("Iterable[Node]", nodes),
|
343
343
|
info=info,
|
344
344
|
before=before,
|
345
345
|
after=after,
|
@@ -39,7 +39,7 @@ from strawberry.types.lazy_type import LazyType
|
|
39
39
|
from strawberry.types.object_type import interface
|
40
40
|
from strawberry.types.object_type import type as strawberry_type
|
41
41
|
from strawberry.types.private import StrawberryPrivate
|
42
|
-
from strawberry.utils.aio import aenumerate, aislice, resolve_awaitable
|
42
|
+
from strawberry.utils.aio import aclosing, aenumerate, aislice, resolve_awaitable
|
43
43
|
from strawberry.utils.inspect import in_async_context
|
44
44
|
from strawberry.utils.typing import eval_type, is_classvar
|
45
45
|
|
@@ -188,7 +188,7 @@ class GlobalID:
|
|
188
188
|
"""
|
189
189
|
n_type = self.resolve_type(info)
|
190
190
|
node: Node | Awaitable[Node] = cast(
|
191
|
-
Awaitable[Node],
|
191
|
+
"Awaitable[Node]",
|
192
192
|
n_type.resolve_node(
|
193
193
|
self.node_id,
|
194
194
|
info=info,
|
@@ -393,7 +393,7 @@ class Node:
|
|
393
393
|
parent_type = info._raw_info.parent_type
|
394
394
|
type_def = info.schema.get_type_by_name(parent_type.name)
|
395
395
|
assert isinstance(type_def, StrawberryObjectDefinition)
|
396
|
-
origin = cast(type[Node], type_def.origin)
|
396
|
+
origin = cast("type[Node]", type_def.origin)
|
397
397
|
resolve_id = origin.resolve_id
|
398
398
|
resolve_typename = origin.resolve_typename
|
399
399
|
|
@@ -404,7 +404,7 @@ class Node:
|
|
404
404
|
|
405
405
|
if inspect.isawaitable(node_id):
|
406
406
|
return cast(
|
407
|
-
GlobalID,
|
407
|
+
"GlobalID",
|
408
408
|
resolve_awaitable(
|
409
409
|
node_id,
|
410
410
|
lambda resolved: GlobalID(
|
@@ -617,7 +617,7 @@ class Node:
|
|
617
617
|
if inspect.isawaitable(retval):
|
618
618
|
return resolve_awaitable(retval, lambda resolved: next(iter(resolved)))
|
619
619
|
|
620
|
-
return next(iter(cast(Iterable[Self], retval)))
|
620
|
+
return next(iter(cast("Iterable[Self]", retval)))
|
621
621
|
|
622
622
|
|
623
623
|
@strawberry_type(description="Information to aid in pagination.")
|
@@ -810,15 +810,15 @@ class ListConnection(Connection[NodeType]):
|
|
810
810
|
while isinstance(field, StrawberryContainer):
|
811
811
|
field = field.of_type
|
812
812
|
|
813
|
-
edge_class = cast(Edge[NodeType], field)
|
813
|
+
edge_class = cast("Edge[NodeType]", field)
|
814
814
|
|
815
815
|
if isinstance(nodes, (AsyncIterator, AsyncIterable)) and in_async_context():
|
816
816
|
|
817
817
|
async def resolver() -> Self:
|
818
818
|
try:
|
819
819
|
iterator = cast(
|
820
|
-
Union[AsyncIterator[NodeType], AsyncIterable[NodeType]],
|
821
|
-
cast(Sequence, nodes)[
|
820
|
+
"Union[AsyncIterator[NodeType], AsyncIterable[NodeType]]",
|
821
|
+
cast("Sequence", nodes)[
|
822
822
|
slice_metadata.start : slice_metadata.overfetch
|
823
823
|
],
|
824
824
|
)
|
@@ -831,24 +831,25 @@ class ListConnection(Connection[NodeType]):
|
|
831
831
|
slice_metadata.overfetch,
|
832
832
|
)
|
833
833
|
|
834
|
-
|
835
|
-
|
836
|
-
|
837
|
-
|
838
|
-
|
839
|
-
|
840
|
-
|
841
|
-
|
842
|
-
|
843
|
-
|
844
|
-
|
845
|
-
|
846
|
-
|
847
|
-
|
848
|
-
|
849
|
-
|
850
|
-
|
851
|
-
|
834
|
+
async with aclosing(iterator):
|
835
|
+
# The slice above might return an object that now is not async
|
836
|
+
# iterable anymore (e.g. an already cached django queryset)
|
837
|
+
if isinstance(iterator, (AsyncIterator, AsyncIterable)):
|
838
|
+
edges: list[Edge] = [
|
839
|
+
edge_class.resolve_edge(
|
840
|
+
cls.resolve_node(v, info=info, **kwargs),
|
841
|
+
cursor=slice_metadata.start + i,
|
842
|
+
)
|
843
|
+
async for i, v in aenumerate(iterator)
|
844
|
+
]
|
845
|
+
else:
|
846
|
+
edges: list[Edge] = [ # type: ignore[no-redef]
|
847
|
+
edge_class.resolve_edge(
|
848
|
+
cls.resolve_node(v, info=info, **kwargs),
|
849
|
+
cursor=slice_metadata.start + i,
|
850
|
+
)
|
851
|
+
for i, v in enumerate(iterator)
|
852
|
+
]
|
852
853
|
|
853
854
|
has_previous_page = slice_metadata.start > 0
|
854
855
|
if (
|
@@ -882,8 +883,10 @@ class ListConnection(Connection[NodeType]):
|
|
882
883
|
|
883
884
|
try:
|
884
885
|
iterator = cast(
|
885
|
-
Union[Iterator[NodeType], Iterable[NodeType]],
|
886
|
-
cast(Sequence, nodes)[
|
886
|
+
"Union[Iterator[NodeType], Iterable[NodeType]]",
|
887
|
+
cast("Sequence", nodes)[
|
888
|
+
slice_metadata.start : slice_metadata.overfetch
|
889
|
+
],
|
887
890
|
)
|
888
891
|
except TypeError:
|
889
892
|
assert isinstance(nodes, (Iterable, Iterator))
|
@@ -3,10 +3,8 @@ from __future__ import annotations
|
|
3
3
|
from io import BytesIO
|
4
4
|
from typing import TYPE_CHECKING, Any, Optional, Union, cast
|
5
5
|
|
6
|
-
from sanic.request import File
|
7
|
-
|
8
6
|
if TYPE_CHECKING:
|
9
|
-
from sanic.request import Request
|
7
|
+
from sanic.request import File, Request
|
10
8
|
|
11
9
|
|
12
10
|
def convert_request_to_files_dict(request: Request) -> dict[str, Any]:
|
@@ -24,7 +22,7 @@ def convert_request_to_files_dict(request: Request) -> dict[str, Any]:
|
|
24
22
|
|
25
23
|
Note that the dictionary entries are lists.
|
26
24
|
"""
|
27
|
-
request_files = cast(Optional[dict[str, list[File]]], request.files)
|
25
|
+
request_files = cast("Optional[dict[str, list[File]]]", request.files)
|
28
26
|
|
29
27
|
if not request_files:
|
30
28
|
return {}
|
@@ -48,7 +48,7 @@ class SanicHTTPRequestAdapter(AsyncHTTPRequestAdapter):
|
|
48
48
|
|
49
49
|
@property
|
50
50
|
def method(self) -> HTTPMethod:
|
51
|
-
return cast(HTTPMethod, self.request.method.upper())
|
51
|
+
return cast("HTTPMethod", self.request.method.upper())
|
52
52
|
|
53
53
|
@property
|
54
54
|
def headers(self) -> Mapping[str, str]:
|