strawberry-graphql 0.276.0.dev1752831589__tar.gz → 0.276.1__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.
Files changed (242) hide show
  1. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/PKG-INFO +1 -1
  2. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/pyproject.toml +7 -3
  3. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/__init__.py +0 -2
  4. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/annotation.py +0 -7
  5. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/__init__.py +6 -6
  6. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/object_type.py +2 -2
  7. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/directives.py +2 -6
  8. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/mask_errors.py +10 -23
  9. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/__init__.py +12 -22
  10. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/async_base_view.py +12 -81
  11. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/sync_base_view.py +8 -1
  12. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/printer/printer.py +2 -10
  13. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/relay/fields.py +5 -0
  14. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/relay/types.py +1 -1
  15. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/config.py +0 -1
  16. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/name_converter.py +3 -2
  17. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/schema.py +25 -58
  18. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/schema_converter.py +62 -36
  19. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/static/graphiql.html +5 -5
  20. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/execution.py +1 -1
  21. strawberry_graphql-0.276.0.dev1752831589/strawberry/schema/_graphql_core.py +0 -53
  22. strawberry_graphql-0.276.0.dev1752831589/strawberry/streamable.py +0 -36
  23. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/LICENSE +0 -0
  24. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/README.md +0 -0
  25. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/__main__.py +0 -0
  26. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/aiohttp/__init__.py +0 -0
  27. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/aiohttp/test/__init__.py +0 -0
  28. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/aiohttp/test/client.py +0 -0
  29. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/aiohttp/views.py +0 -0
  30. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/asgi/__init__.py +0 -0
  31. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/asgi/test/__init__.py +0 -0
  32. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/asgi/test/client.py +0 -0
  33. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/chalice/__init__.py +0 -0
  34. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/chalice/views.py +0 -0
  35. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/channels/__init__.py +0 -0
  36. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/channels/handlers/__init__.py +0 -0
  37. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/channels/handlers/base.py +0 -0
  38. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/channels/handlers/http_handler.py +0 -0
  39. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/channels/handlers/ws_handler.py +0 -0
  40. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/channels/router.py +0 -0
  41. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/channels/testing.py +0 -0
  42. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/app.py +0 -0
  43. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/__init__.py +0 -0
  44. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/codegen.py +0 -0
  45. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/export_schema.py +0 -0
  46. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/locate_definition.py +0 -0
  47. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/schema_codegen.py +0 -0
  48. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/server.py +0 -0
  49. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/upgrade/__init__.py +0 -0
  50. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/upgrade/_fake_progress.py +0 -0
  51. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/commands/upgrade/_run_codemod.py +0 -0
  52. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/constants.py +0 -0
  53. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/debug_server.py +0 -0
  54. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/utils/__init__.py +0 -0
  55. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/cli/utils/load_schema.py +0 -0
  56. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codegen/__init__.py +0 -0
  57. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codegen/exceptions.py +0 -0
  58. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codegen/plugins/__init__.py +0 -0
  59. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codegen/plugins/print_operation.py +0 -0
  60. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codegen/plugins/python.py +0 -0
  61. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codegen/plugins/typescript.py +0 -0
  62. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codegen/query_codegen.py +0 -0
  63. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codegen/types.py +0 -0
  64. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codemods/__init__.py +0 -0
  65. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codemods/annotated_unions.py +0 -0
  66. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/codemods/update_imports.py +0 -0
  67. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/dataloader.py +0 -0
  68. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/directive.py +0 -0
  69. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/django/__init__.py +0 -0
  70. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/django/apps.py +0 -0
  71. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/django/context.py +0 -0
  72. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/django/test/__init__.py +0 -0
  73. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/django/test/client.py +0 -0
  74. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/django/views.py +0 -0
  75. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/__init__.py +0 -0
  76. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/conflicting_arguments.py +0 -0
  77. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/duplicated_type_name.py +0 -0
  78. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/exception.py +0 -0
  79. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/exception_source.py +0 -0
  80. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/handler.py +0 -0
  81. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/invalid_argument_type.py +0 -0
  82. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/invalid_superclass_interface.py +0 -0
  83. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/invalid_union_type.py +0 -0
  84. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/missing_arguments_annotations.py +0 -0
  85. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/missing_dependencies.py +0 -0
  86. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/missing_field_annotation.py +0 -0
  87. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/missing_return_annotation.py +0 -0
  88. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/object_is_not_a_class.py +0 -0
  89. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/object_is_not_an_enum.py +0 -0
  90. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/permission_fail_silently_requires_optional.py +0 -0
  91. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/private_strawberry_field.py +0 -0
  92. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/scalar_already_registered.py +0 -0
  93. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/syntax.py +0 -0
  94. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/unresolved_field_type.py +0 -0
  95. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/utils/__init__.py +0 -0
  96. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/exceptions/utils/source_finder.py +0 -0
  97. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/__init__.py +0 -0
  98. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/__init__.py +0 -0
  99. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/_compat.py +0 -0
  100. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/conversion.py +0 -0
  101. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/conversion_types.py +0 -0
  102. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/error_type.py +0 -0
  103. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/exceptions.py +0 -0
  104. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/fields.py +0 -0
  105. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/experimental/pydantic/utils.py +0 -0
  106. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/ext/LICENSE +0 -0
  107. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/ext/__init__.py +0 -0
  108. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/ext/dataclasses/LICENSE +0 -0
  109. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/ext/dataclasses/README.md +0 -0
  110. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/ext/dataclasses/__init__.py +0 -0
  111. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/ext/dataclasses/dataclasses.py +0 -0
  112. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/ext/mypy_plugin.py +0 -0
  113. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/__init__.py +0 -0
  114. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/add_validation_rules.py +0 -0
  115. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/base_extension.py +0 -0
  116. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/context.py +0 -0
  117. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/disable_introspection.py +0 -0
  118. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/disable_validation.py +0 -0
  119. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/field_extension.py +0 -0
  120. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/max_aliases.py +0 -0
  121. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/max_tokens.py +0 -0
  122. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/parser_cache.py +0 -0
  123. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/pyinstrument.py +0 -0
  124. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/query_depth_limiter.py +0 -0
  125. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/runner.py +0 -0
  126. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/tracing/__init__.py +0 -0
  127. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/tracing/apollo.py +0 -0
  128. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/tracing/datadog.py +0 -0
  129. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/tracing/opentelemetry.py +0 -0
  130. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/tracing/utils.py +0 -0
  131. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/utils.py +0 -0
  132. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/extensions/validation_cache.py +0 -0
  133. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/fastapi/__init__.py +0 -0
  134. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/fastapi/context.py +0 -0
  135. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/fastapi/router.py +0 -0
  136. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/__init__.py +0 -0
  137. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/argument.py +0 -0
  138. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/enum.py +0 -0
  139. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/field.py +0 -0
  140. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/mutation.py +0 -0
  141. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/object_type.py +0 -0
  142. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/scalar.py +0 -0
  143. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/schema.py +0 -0
  144. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/schema_directive.py +0 -0
  145. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/schema_directives.py +0 -0
  146. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/types.py +0 -0
  147. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/federation/union.py +0 -0
  148. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/field_extensions/__init__.py +0 -0
  149. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/field_extensions/input_mutation.py +0 -0
  150. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/file_uploads/__init__.py +0 -0
  151. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/file_uploads/scalars.py +0 -0
  152. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/file_uploads/utils.py +0 -0
  153. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/flask/__init__.py +0 -0
  154. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/flask/views.py +0 -0
  155. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/base.py +0 -0
  156. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/exceptions.py +0 -0
  157. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/ides.py +0 -0
  158. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/parse_content_type.py +0 -0
  159. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/temporal_response.py +0 -0
  160. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/types.py +0 -0
  161. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/http/typevars.py +0 -0
  162. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/litestar/__init__.py +0 -0
  163. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/litestar/controller.py +0 -0
  164. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/parent.py +0 -0
  165. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/permission.py +0 -0
  166. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/printer/__init__.py +0 -0
  167. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/printer/ast_from_value.py +0 -0
  168. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/py.typed +0 -0
  169. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/quart/__init__.py +0 -0
  170. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/quart/views.py +0 -0
  171. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/relay/__init__.py +0 -0
  172. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/relay/exceptions.py +0 -0
  173. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/relay/utils.py +0 -0
  174. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/resolvers.py +0 -0
  175. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/sanic/__init__.py +0 -0
  176. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/sanic/context.py +0 -0
  177. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/sanic/utils.py +0 -0
  178. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/sanic/views.py +0 -0
  179. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/scalars.py +0 -0
  180. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/__init__.py +0 -0
  181. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/base.py +0 -0
  182. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/compat.py +0 -0
  183. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/exceptions.py +0 -0
  184. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/types/__init__.py +0 -0
  185. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/types/base_scalars.py +0 -0
  186. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/types/concrete_type.py +0 -0
  187. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/types/scalar.py +0 -0
  188. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/validation_rules/__init__.py +0 -0
  189. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema/validation_rules/one_of.py +0 -0
  190. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema_codegen/__init__.py +0 -0
  191. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema_directive.py +0 -0
  192. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/schema_directives.py +0 -0
  193. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/static/apollo-sandbox.html +0 -0
  194. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/static/pathfinder.html +0 -0
  195. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/subscriptions/__init__.py +0 -0
  196. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/subscriptions/protocols/__init__.py +0 -0
  197. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/subscriptions/protocols/graphql_transport_ws/__init__.py +0 -0
  198. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/subscriptions/protocols/graphql_transport_ws/handlers.py +0 -0
  199. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/subscriptions/protocols/graphql_transport_ws/types.py +0 -0
  200. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/subscriptions/protocols/graphql_ws/__init__.py +0 -0
  201. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/subscriptions/protocols/graphql_ws/handlers.py +0 -0
  202. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/subscriptions/protocols/graphql_ws/types.py +0 -0
  203. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/test/__init__.py +0 -0
  204. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/test/client.py +0 -0
  205. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/tools/__init__.py +0 -0
  206. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/tools/create_type.py +0 -0
  207. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/tools/merge_types.py +0 -0
  208. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/__init__.py +0 -0
  209. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/arguments.py +0 -0
  210. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/auto.py +0 -0
  211. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/base.py +0 -0
  212. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/cast.py +0 -0
  213. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/enum.py +0 -0
  214. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/field.py +0 -0
  215. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/fields/__init__.py +0 -0
  216. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/fields/resolver.py +0 -0
  217. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/graphql.py +0 -0
  218. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/info.py +0 -0
  219. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/lazy_type.py +0 -0
  220. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/maybe.py +0 -0
  221. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/mutation.py +0 -0
  222. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/nodes.py +0 -0
  223. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/object_type.py +0 -0
  224. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/private.py +0 -0
  225. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/scalar.py +0 -0
  226. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/type_resolver.py +0 -0
  227. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/union.py +0 -0
  228. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/types/unset.py +0 -0
  229. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/__init__.py +0 -0
  230. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/aio.py +0 -0
  231. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/await_maybe.py +0 -0
  232. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/dataclasses.py +0 -0
  233. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/debug.py +0 -0
  234. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/deprecations.py +0 -0
  235. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/graphql_lexer.py +0 -0
  236. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/importer.py +0 -0
  237. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/inspect.py +0 -0
  238. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/locate_definition.py +0 -0
  239. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/logging.py +0 -0
  240. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/operation.py +0 -0
  241. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/str_converters.py +0 -0
  242. {strawberry_graphql-0.276.0.dev1752831589 → strawberry_graphql-0.276.1}/strawberry/utils/typing.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: strawberry-graphql
3
- Version: 0.276.0.dev1752831589
3
+ Version: 0.276.1
4
4
  Summary: A library for creating GraphQL APIs
5
5
  License: MIT
6
6
  Keywords: graphql,api,rest,starlette,async
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "strawberry-graphql"
3
- version = "0.276.0.dev.1752831589"
3
+ version = "0.276.1"
4
4
  description = "A library for creating GraphQL APIs"
5
5
  authors = [{ name = "Patrick Arminio", email = "patrick.arminio@gmail.com" }]
6
6
  license = { text = "MIT" }
@@ -67,7 +67,7 @@ packages = [{ include = "strawberry" }]
67
67
  include = ["strawberry/py.typed"]
68
68
 
69
69
  [tool.poetry.group.dev.dependencies]
70
- ruff = "^0.11.4"
70
+ ruff = "^0.12.3"
71
71
  asgiref = "^3.2"
72
72
  email-validator = { version = ">=1.1.3,<3.0.0", optional = false }
73
73
  freezegun = "^1.2.1"
@@ -220,6 +220,7 @@ ignore = [
220
220
  # after we drop support for Python 3.9
221
221
  "UP006",
222
222
  "UP007",
223
+ "UP045",
223
224
 
224
225
  # we use asserts in tests and to hint mypy
225
226
  "S101",
@@ -308,6 +309,9 @@ ignore = [
308
309
  # Don't force if branches to be converted to "or"
309
310
  "SIM114",
310
311
 
312
+ # Allow imports inside functions
313
+ "PLC0415",
314
+
311
315
  # ruff formatter recommends to disable those, as they conflict with it
312
316
  # we don't need to ever enable those.
313
317
  "COM812",
@@ -323,8 +327,8 @@ ignore = [
323
327
  "Q002",
324
328
  "Q003",
325
329
  "W191",
326
- "PLR0915",
327
330
  ]
331
+ exclude = ["tests/python_312/*"] # SyntaxError because we support Python 3.9+
328
332
 
329
333
  [tool.ruff.lint.per-file-ignores]
330
334
  ".github/*" = ["INP001"]
@@ -11,7 +11,6 @@ from .permission import BasePermission
11
11
  from .scalars import ID
12
12
  from .schema import Schema
13
13
  from .schema_directive import schema_directive
14
- from .streamable import Streamable
15
14
  from .types.arguments import argument
16
15
  from .types.auto import auto
17
16
  from .types.cast import cast
@@ -38,7 +37,6 @@ __all__ = [
38
37
  "Private",
39
38
  "Schema",
40
39
  "Some",
41
- "Streamable",
42
40
  "argument",
43
41
  "asdict",
44
42
  "auto",
@@ -17,7 +17,6 @@ from typing import (
17
17
  )
18
18
  from typing_extensions import Self, get_args, get_origin
19
19
 
20
- from strawberry.streamable import StrawberryStreamable
21
20
  from strawberry.types.base import (
22
21
  StrawberryList,
23
22
  StrawberryMaybe,
@@ -144,8 +143,6 @@ class StrawberryAnnotation:
144
143
 
145
144
  if self._is_lazy_type(evaled_type):
146
145
  return evaled_type
147
- if self._is_streamable(evaled_type, args):
148
- return self.create_list(list[evaled_type]) # type: ignore[valid-type]
149
146
  if self._is_list(evaled_type):
150
147
  return self.create_list(evaled_type)
151
148
  if self._is_maybe(evaled_type):
@@ -335,10 +332,6 @@ class StrawberryAnnotation:
335
332
  def _is_maybe(cls, annotation: Any) -> bool:
336
333
  return _annotation_is_maybe(annotation)
337
334
 
338
- @classmethod
339
- def _is_streamable(cls, annotation: Any, args: list[Any]) -> bool:
340
- return any(isinstance(arg, StrawberryStreamable) for arg in args)
341
-
342
335
  @classmethod
343
336
  def _is_strawberry_type(cls, evaled_type: Any) -> bool:
344
337
  # Prevent import cycles
@@ -1,15 +1,15 @@
1
1
  try:
2
2
  from .app import app
3
- from .commands.codegen import codegen as codegen # noqa: PLC0414
4
- from .commands.export_schema import export_schema as export_schema # noqa: PLC0414
3
+ from .commands.codegen import codegen as codegen
4
+ from .commands.export_schema import export_schema as export_schema
5
5
  from .commands.locate_definition import (
6
- locate_definition as locate_definition, # noqa: PLC0414
6
+ locate_definition as locate_definition,
7
7
  )
8
8
  from .commands.schema_codegen import (
9
- schema_codegen as schema_codegen, # noqa: PLC0414
9
+ schema_codegen as schema_codegen,
10
10
  )
11
- from .commands.server import server as server # noqa: PLC0414
12
- from .commands.upgrade import upgrade as upgrade # noqa: PLC0414
11
+ from .commands.server import server as server
12
+ from .commands.upgrade import upgrade as upgrade
13
13
 
14
14
  def run() -> None:
15
15
  app()
@@ -116,7 +116,7 @@ if TYPE_CHECKING:
116
116
  )
117
117
 
118
118
 
119
- def type(
119
+ def type( # noqa: PLR0915
120
120
  model: builtins.type[PydanticModel],
121
121
  *,
122
122
  fields: Optional[list[str]] = None,
@@ -129,7 +129,7 @@ def type(
129
129
  include_computed: bool = False,
130
130
  use_pydantic_alias: bool = True,
131
131
  ) -> Callable[..., builtins.type[StrawberryTypeFromPydantic[PydanticModel]]]:
132
- def wrap(cls: Any) -> builtins.type[StrawberryTypeFromPydantic[PydanticModel]]:
132
+ def wrap(cls: Any) -> builtins.type[StrawberryTypeFromPydantic[PydanticModel]]: # noqa: PLR0915
133
133
  compat = PydanticCompat.from_model(model)
134
134
  model_fields = compat.get_model_fields(model, include_computed=include_computed)
135
135
  original_fields_set = set(fields) if fields else set()
@@ -29,9 +29,7 @@ class DirectivesExtension(SchemaExtension):
29
29
  ) -> AwaitableOrValue[Any]:
30
30
  value = await await_maybe(_next(root, info, *args, **kwargs))
31
31
 
32
- nodes = list(info.field_nodes)
33
-
34
- for directive in nodes[0].directives:
32
+ for directive in info.field_nodes[0].directives:
35
33
  if directive.name.value in SPECIFIED_DIRECTIVES:
36
34
  continue
37
35
  strawberry_directive, arguments = process_directive(directive, value, info)
@@ -51,9 +49,7 @@ class DirectivesExtensionSync(SchemaExtension):
51
49
  ) -> AwaitableOrValue[Any]:
52
50
  value = _next(root, info, *args, **kwargs)
53
51
 
54
- nodes = list(info.field_nodes)
55
-
56
- for directive in nodes[0].directives:
52
+ for directive in info.field_nodes[0].directives:
57
53
  if directive.name.value in SPECIFIED_DIRECTIVES:
58
54
  continue
59
55
  strawberry_directive, arguments = process_directive(directive, value, info)
@@ -1,8 +1,7 @@
1
1
  from collections.abc import Iterator
2
- from typing import Any, Callable
2
+ from typing import Callable
3
3
 
4
4
  from graphql.error import GraphQLError
5
- from graphql.execution import ExecutionResult
6
5
 
7
6
  from strawberry.extensions.base_extension import SchemaExtension
8
7
 
@@ -34,30 +33,18 @@ class MaskErrors(SchemaExtension):
34
33
  original_error=None,
35
34
  )
36
35
 
37
- # TODO: proper typing
38
- def _process_result(self, result: Any) -> None:
39
- if not result.errors:
40
- return
41
-
42
- processed_errors: list[GraphQLError] = []
43
-
44
- for error in result.errors:
45
- if self.should_mask_error(error):
46
- processed_errors.append(self.anonymise_error(error))
47
- else:
48
- processed_errors.append(error)
49
-
50
- result.errors = processed_errors
51
-
52
36
  def on_operation(self) -> Iterator[None]:
53
37
  yield
54
-
55
38
  result = self.execution_context.result
56
-
57
- if isinstance(result, ExecutionResult):
58
- self._process_result(result)
59
- else:
60
- self._process_result(result.initial_result)
39
+ if result and result.errors:
40
+ processed_errors: list[GraphQLError] = []
41
+ for error in result.errors:
42
+ if self.should_mask_error(error):
43
+ processed_errors.append(self.anonymise_error(error))
44
+ else:
45
+ processed_errors.append(error)
46
+
47
+ result.errors = processed_errors
61
48
 
62
49
 
63
50
  __all__ = ["MaskErrors"]
@@ -1,36 +1,26 @@
1
1
  from __future__ import annotations
2
2
 
3
3
  from dataclasses import dataclass
4
- from typing import Any, Optional
4
+ from typing import TYPE_CHECKING, Any, Optional
5
5
  from typing_extensions import Literal, TypedDict
6
6
 
7
- from strawberry.schema._graphql_core import (
8
- GraphQLIncrementalExecutionResults,
9
- ResultType,
10
- )
7
+ if TYPE_CHECKING:
8
+ from strawberry.types import ExecutionResult
11
9
 
12
10
 
13
11
  class GraphQLHTTPResponse(TypedDict, total=False):
14
12
  data: Optional[dict[str, object]]
15
13
  errors: Optional[list[object]]
16
14
  extensions: Optional[dict[str, object]]
17
- hasNext: Optional[bool]
18
- completed: Optional[list[Any]]
19
- pending: Optional[list[Any]]
20
- initial: Optional[list[Any]]
21
- incremental: Optional[list[Any]]
22
-
23
-
24
- def process_result(result: ResultType) -> GraphQLHTTPResponse:
25
- if isinstance(result, GraphQLIncrementalExecutionResults):
26
- return result
27
-
28
- errors, extensions = result.errors, result.extensions
29
- data: GraphQLHTTPResponse = {
30
- "data": result.data,
31
- **({"errors": [err.formatted for err in errors]} if errors else {}),
32
- **({"extensions": extensions} if extensions else {}),
33
- }
15
+
16
+
17
+ def process_result(result: ExecutionResult) -> GraphQLHTTPResponse:
18
+ data: GraphQLHTTPResponse = {"data": result.data}
19
+
20
+ if result.errors:
21
+ data["errors"] = [err.formatted for err in result.errors]
22
+ if result.extensions:
23
+ data["extensions"] = result.extensions
34
24
 
35
25
  return data
36
26
 
@@ -25,9 +25,6 @@ from strawberry.http import (
25
25
  process_result,
26
26
  )
27
27
  from strawberry.http.ides import GraphQL_IDE
28
- from strawberry.schema._graphql_core import (
29
- GraphQLIncrementalExecutionResults,
30
- )
31
28
  from strawberry.schema.base import BaseSchema
32
29
  from strawberry.schema.exceptions import (
33
30
  CannotGetOperationTypeError,
@@ -355,75 +352,6 @@ class AsyncBaseHTTPView(
355
352
  "Content-Type": "multipart/mixed;boundary=graphql;subscriptionSpec=1.0,application/json",
356
353
  },
357
354
  )
358
- if isinstance(result, GraphQLIncrementalExecutionResults):
359
-
360
- async def stream() -> AsyncGenerator[str, None]:
361
- yield "---"
362
-
363
- response = await self.process_result(request, result.initial_result)
364
-
365
- response["hasNext"] = result.initial_result.has_next
366
- response["pending"] = [
367
- p.formatted for p in result.initial_result.pending
368
- ]
369
- response["extensions"] = result.initial_result.extensions
370
-
371
- yield self.encode_multipart_data(response, "-")
372
-
373
- all_pending = result.initial_result.pending
374
-
375
- async for value in result.subsequent_results:
376
- response = {
377
- "hasNext": value.has_next,
378
- "extensions": value.extensions,
379
- }
380
-
381
- if value.pending:
382
- response["pending"] = [p.formatted for p in value.pending]
383
-
384
- if value.completed:
385
- response["completed"] = [p.formatted for p in value.completed]
386
-
387
- if value.incremental:
388
- incremental = []
389
-
390
- all_pending.extend(value.pending)
391
-
392
- for incremental_value in value.incremental:
393
- pending_value = next(
394
- (
395
- v
396
- for v in all_pending
397
- if v.id == incremental_value.id
398
- ),
399
- None,
400
- )
401
-
402
- assert pending_value
403
-
404
- incremental.append(
405
- {
406
- **incremental_value.formatted,
407
- "path": pending_value.path,
408
- "label": pending_value.label,
409
- }
410
- )
411
-
412
- response["incremental"] = incremental
413
-
414
- yield self.encode_multipart_data(response, "-")
415
-
416
- yield "--\r\n"
417
-
418
- return await self.create_streaming_response(
419
- request,
420
- stream,
421
- sub_response,
422
- headers={
423
- "Transfer-Encoding": "chunked",
424
- "Content-Type": 'multipart/mixed; boundary="-"',
425
- },
426
- )
427
355
 
428
356
  response_data = await self.process_result(request=request, result=result)
429
357
 
@@ -435,16 +363,12 @@ class AsyncBaseHTTPView(
435
363
  )
436
364
 
437
365
  def encode_multipart_data(self, data: Any, separator: str) -> str:
438
- encoded_data = self.encode_json(data)
439
-
440
366
  return "".join(
441
367
  [
442
- "\r\n",
443
- "Content-Type: application/json; charset=utf-8\r\n",
444
- "Content-Length: " + str(len(encoded_data)) + "\r\n",
445
- "\r\n",
446
- encoded_data,
447
- f"\r\n--{separator}",
368
+ f"\r\n--{separator}\r\n",
369
+ "Content-Type: application/json\r\n\r\n",
370
+ self.encode_json(data),
371
+ "\n",
448
372
  ]
449
373
  )
450
374
 
@@ -617,11 +541,18 @@ class AsyncBaseHTTPView(
617
541
  "The GraphQL operation's `variables` must be an object or null, if provided.",
618
542
  )
619
543
 
544
+ extensions = data.get("extensions")
545
+ if not isinstance(extensions, (dict, type(None))):
546
+ raise HTTPException(
547
+ 400,
548
+ "The GraphQL operation's `extensions` must be an object or null, if provided.",
549
+ )
550
+
620
551
  return GraphQLRequestData(
621
552
  query=query,
622
553
  variables=variables,
623
554
  operation_name=data.get("operationName"),
624
- extensions=data.get("extensions"),
555
+ extensions=extensions,
625
556
  protocol=protocol,
626
557
  )
627
558
 
@@ -166,11 +166,18 @@ class SyncBaseHTTPView(
166
166
  "The GraphQL operation's `variables` must be an object or null, if provided.",
167
167
  )
168
168
 
169
+ extensions = data.get("extensions")
170
+ if not isinstance(extensions, (dict, type(None))):
171
+ raise HTTPException(
172
+ 400,
173
+ "The GraphQL operation's `extensions` must be an object or null, if provided.",
174
+ )
175
+
169
176
  return GraphQLRequestData(
170
177
  query=query,
171
178
  variables=variables,
172
179
  operation_name=data.get("operationName"),
173
- extensions=data.get("extensions"),
180
+ extensions=extensions,
174
181
  )
175
182
 
176
183
  def _handle_errors(
@@ -561,9 +561,9 @@ def print_schema_definition(
561
561
  def print_directive(
562
562
  directive: GraphQLDirective, *, schema: BaseSchema
563
563
  ) -> Optional[str]:
564
- strawberry_directive = directive.extensions.get("strawberry-definition")
564
+ strawberry_directive = directive.extensions["strawberry-definition"]
565
565
 
566
- if strawberry_directive is None or (
566
+ if (
567
567
  isinstance(strawberry_directive, StrawberrySchemaDirective)
568
568
  and not strawberry_directive.print_definition
569
569
  ):
@@ -621,14 +621,6 @@ def print_schema(schema: BaseSchema) -> str:
621
621
  if (printed_directive := print_directive(directive, schema=schema)) is not None
622
622
  ]
623
623
 
624
- if schema.config.enable_experimental_incremental_execution:
625
- directives.append(
626
- "directive @defer(if: Boolean, label: String) on FRAGMENT_SPREAD | INLINE_FRAGMENT"
627
- )
628
- directives.append(
629
- "directive @stream(if: Boolean, label: String, initialCount: Int = 0) on FIELD"
630
- )
631
-
632
624
  def _name_getter(type_: Any) -> str:
633
625
  if hasattr(type_, "name"):
634
626
  return type_.name
@@ -261,7 +261,12 @@ class ConnectionExtension(FieldExtension):
261
261
  if isinstance(f_type, StrawberryOptional):
262
262
  f_type = f_type.of_type
263
263
 
264
+ if isinstance(f_type, LazyType):
265
+ f_type = f_type.resolve_type()
266
+
264
267
  type_origin = get_origin(f_type) if is_generic_alias(f_type) else f_type
268
+ if isinstance(type_origin, LazyType):
269
+ type_origin = type_origin.resolve_type()
265
270
 
266
271
  if not isinstance(type_origin, type) or not issubclass(type_origin, Connection):
267
272
  raise RelayWrongAnnotationError(field.name, cast("type", field.origin))
@@ -762,7 +762,7 @@ class ListConnection(Connection[NodeType]):
762
762
  )
763
763
 
764
764
  @classmethod
765
- def resolve_connection(
765
+ def resolve_connection( # noqa: PLR0915
766
766
  cls,
767
767
  nodes: NodeIterableType[NodeType],
768
768
  *,
@@ -17,7 +17,6 @@ class StrawberryConfig:
17
17
  relay_use_legacy_global_id: bool = False
18
18
  disable_field_suggestions: bool = False
19
19
  info_class: type[Info] = Info
20
- enable_experimental_incremental_execution: bool = False
21
20
  _unsafe_disable_same_type_validation: bool = False
22
21
 
23
22
  def __post_init__(
@@ -150,8 +150,9 @@ class NameConverter:
150
150
  type_ = eval_type(type_)
151
151
 
152
152
  if isinstance(type_, LazyType):
153
- name = type_.type_name
154
- elif isinstance(type_, EnumDefinition):
153
+ type_ = type_.resolve_type()
154
+
155
+ if isinstance(type_, EnumDefinition):
155
156
  name = type_.name
156
157
  elif isinstance(type_, StrawberryUnion):
157
158
  name = type_.graphql_name if type_.graphql_name else self.from_union(type_)
@@ -15,6 +15,7 @@ from typing import (
15
15
  cast,
16
16
  )
17
17
 
18
+ from graphql import ExecutionContext as GraphQLExecutionContext
18
19
  from graphql import ExecutionResult as GraphQLExecutionResult
19
20
  from graphql import (
20
21
  ExecutionResult as OriginalExecutionResult,
@@ -35,6 +36,7 @@ from graphql import (
35
36
  parse,
36
37
  validate_schema,
37
38
  )
39
+ from graphql.execution import execute, subscribe
38
40
  from graphql.execution.middleware import MiddlewareManager
39
41
  from graphql.type.directives import specified_directives
40
42
  from graphql.validation import validate
@@ -67,15 +69,6 @@ from strawberry.utils.aio import aclosing
67
69
  from strawberry.utils.await_maybe import await_maybe
68
70
 
69
71
  from . import compat
70
- from ._graphql_core import (
71
- GraphQLExecutionContext,
72
- GraphQLIncrementalExecutionResults,
73
- ResultType,
74
- execute,
75
- experimental_execute_incrementally,
76
- incremental_execution_directives,
77
- subscribe,
78
- )
79
72
  from .base import BaseSchema
80
73
  from .config import StrawberryConfig
81
74
  from .exceptions import CannotGetOperationTypeError, InvalidOperationTypeError
@@ -84,6 +77,7 @@ if TYPE_CHECKING:
84
77
  from collections.abc import Iterable, Mapping
85
78
  from typing_extensions import TypeAlias
86
79
 
80
+ from graphql.execution.collect_fields import FieldGroup # type: ignore
87
81
  from graphql.language import DocumentNode
88
82
  from graphql.pyutils import Path
89
83
  from graphql.type import GraphQLResolveInfo
@@ -105,7 +99,6 @@ OriginSubscriptionResult = Union[
105
99
  AsyncIterator[OriginalExecutionResult],
106
100
  ]
107
101
 
108
-
109
102
  DEFAULT_ALLOWED_OPERATION_TYPES = {
110
103
  OperationType.QUERY,
111
104
  OperationType.MUTATION,
@@ -175,18 +168,17 @@ class StrawberryGraphQLCoreExecutionContext(GraphQLExecutionContext):
175
168
 
176
169
  self.operation_extensions = operation_extensions
177
170
 
178
- if IS_GQL_33:
179
-
180
- def build_resolve_info(
181
- self,
182
- field_def: GraphQLField,
183
- field_nodes: list[FieldNode],
184
- parent_type: GraphQLObjectType,
185
- path: Path,
186
- ) -> GraphQLResolveInfo:
171
+ def build_resolve_info(
172
+ self,
173
+ field_def: GraphQLField,
174
+ field_group: FieldGroup,
175
+ parent_type: GraphQLObjectType,
176
+ path: Path,
177
+ ) -> GraphQLResolveInfo:
178
+ if IS_GQL_33:
187
179
  return _OperationContextAwareGraphQLResolveInfo( # type: ignore
188
- field_nodes[0].name.value,
189
- field_nodes,
180
+ field_group.fields[0].node.name.value,
181
+ field_group.to_nodes(),
190
182
  field_def.type,
191
183
  parent_type,
192
184
  path,
@@ -200,6 +192,13 @@ class StrawberryGraphQLCoreExecutionContext(GraphQLExecutionContext):
200
192
  self.operation_extensions,
201
193
  )
202
194
 
195
+ return super().build_resolve_info(
196
+ field_def,
197
+ field_group,
198
+ parent_type,
199
+ path,
200
+ )
201
+
203
202
 
204
203
  class Schema(BaseSchema):
205
204
  def __init__(
@@ -322,16 +321,11 @@ class Schema(BaseSchema):
322
321
  graphql_types.append(graphql_type)
323
322
 
324
323
  try:
325
- directives = specified_directives + tuple(graphql_directives) # type: ignore
326
-
327
- if self.config.enable_experimental_incremental_execution:
328
- directives = tuple(directives) + tuple(incremental_execution_directives)
329
-
330
324
  self._schema = GraphQLSchema(
331
325
  query=query_type,
332
326
  mutation=mutation_type,
333
327
  subscription=subscription_type if subscription else None,
334
- directives=directives, # type: ignore
328
+ directives=specified_directives + tuple(graphql_directives),
335
329
  types=graphql_types,
336
330
  extensions={
337
331
  GraphQLCoreConverter.DEFINITION_BACKREF: self,
@@ -524,16 +518,12 @@ class Schema(BaseSchema):
524
518
  async def _handle_execution_result(
525
519
  self,
526
520
  context: ExecutionContext,
527
- result: ResultType,
521
+ result: Union[GraphQLExecutionResult, ExecutionResult],
528
522
  extensions_runner: SchemaExtensionsRunner,
529
523
  *,
530
524
  # TODO: can we remove this somehow, see comment in execute
531
525
  skip_process_errors: bool = False,
532
526
  ) -> ExecutionResult:
533
- # TODO: handle this, also, why do we have both GraphQLExecutionResult and ExecutionResult?
534
- if isinstance(result, GraphQLIncrementalExecutionResults):
535
- return result
536
-
537
527
  # Set errors on the context so that it's easier
538
528
  # to access in extensions
539
529
  if result.errors:
@@ -576,17 +566,6 @@ class Schema(BaseSchema):
576
566
  extensions_runner = self.create_extensions_runner(execution_context, extensions)
577
567
  middleware_manager = self._get_middleware_manager(extensions)
578
568
 
579
- execute_function = execute
580
-
581
- if self.config.enable_experimental_incremental_execution:
582
- execute_function = experimental_execute_incrementally
583
-
584
- if execute_function is None:
585
- raise RuntimeError(
586
- "Incremental execution is enabled but experimental_execute_incrementally is not available, "
587
- "please install graphql-core>=3.3.0"
588
- )
589
-
590
569
  custom_context_kwargs = self._get_custom_context_kwargs(operation_extensions)
591
570
 
592
571
  try:
@@ -607,7 +586,7 @@ class Schema(BaseSchema):
607
586
  async with extensions_runner.executing():
608
587
  if not execution_context.result:
609
588
  result = await await_maybe(
610
- execute_function(
589
+ execute(
611
590
  self._schema,
612
591
  execution_context.graphql_document,
613
592
  root_value=execution_context.root_value,
@@ -624,9 +603,7 @@ class Schema(BaseSchema):
624
603
  result = execution_context.result
625
604
  # Also set errors on the execution_context so that it's easier
626
605
  # to access in extensions
627
-
628
- # TODO: maybe here use the first result from incremental execution if it exists
629
- if isinstance(result, GraphQLExecutionResult) and result.errors:
606
+ if result.errors:
630
607
  execution_context.errors = result.errors
631
608
 
632
609
  # Run the `Schema.process_errors` function here before
@@ -682,16 +659,6 @@ class Schema(BaseSchema):
682
659
  extensions_runner = self.create_extensions_runner(execution_context, extensions)
683
660
  middleware_manager = self._get_middleware_manager(extensions)
684
661
 
685
- execute_function = execute
686
-
687
- if self.config.enable_experimental_incremental_execution:
688
- execute_function = experimental_execute_incrementally
689
-
690
- if execute_function is None:
691
- raise RuntimeError(
692
- "Incremental execution is enabled but experimental_execute_incrementally is not available, "
693
- "please install graphql-core>=3.3.0"
694
- )
695
662
  custom_context_kwargs = self._get_custom_context_kwargs(operation_extensions)
696
663
 
697
664
  try:
@@ -742,7 +709,7 @@ class Schema(BaseSchema):
742
709
 
743
710
  with extensions_runner.executing():
744
711
  if not execution_context.result:
745
- result = execute_function(
712
+ result = execute(
746
713
  self._schema,
747
714
  execution_context.graphql_document,
748
715
  root_value=execution_context.root_value,