strawberry-graphql 0.264.0__py3-none-any.whl → 0.264.1__py3-none-any.whl

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.
@@ -83,14 +83,14 @@ def convert_pydantic_model_to_strawberry_class(
83
83
  field = cast("StrawberryField", field_)
84
84
  python_name = field.python_name
85
85
 
86
- data_from_extra = extra.get(python_name, None)
87
- data_from_model = (
88
- getattr(model_instance, python_name, None) if model_instance else None
89
- )
90
-
91
86
  # only convert and add fields to kwargs if they are present in the `__init__`
92
87
  # method of the class
93
88
  if field.init:
89
+ data_from_extra = extra.get(python_name, None)
90
+ data_from_model = (
91
+ getattr(model_instance, python_name, None) if model_instance else None
92
+ )
93
+
94
94
  kwargs[python_name] = _convert_from_pydantic_to_strawberry_type(
95
95
  field.type, data_from_model, extra=data_from_extra
96
96
  )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: strawberry-graphql
3
- Version: 0.264.0
3
+ Version: 0.264.1
4
4
  Summary: A library for creating GraphQL APIs
5
5
  License: MIT
6
6
  Keywords: graphql,api,rest,starlette,async
@@ -74,7 +74,7 @@ strawberry/exceptions/utils/source_finder.py,sha256=kqSjCGIlnkD0DuCBYElqConp9wAv
74
74
  strawberry/experimental/__init__.py,sha256=2HP5XtxL8ZKsPp4EDRAbMCqiP7p2V4Cca278JUGxnt0,102
75
75
  strawberry/experimental/pydantic/__init__.py,sha256=UpO8wHNXGpoCYp34YStViInO1tsrGsMyhTVubTpJY7Y,255
76
76
  strawberry/experimental/pydantic/_compat.py,sha256=CUc7SmGA-viYoBgD4L8X483yTGyDKaKMjX3WYWkiohg,9710
77
- strawberry/experimental/pydantic/conversion.py,sha256=LBkR3CukdZx9LLvmDyK75YhoOrl0AlF3UD7x8HYr7us,4226
77
+ strawberry/experimental/pydantic/conversion.py,sha256=xspWZtbCuhLeStf12X60c5cOrKp4ilVDlnW-tRU0_YY,4242
78
78
  strawberry/experimental/pydantic/conversion_types.py,sha256=jf7PR5Q7hgo4J_AuxBK-BVj-8MC6vIg1k1pUfGfGTL8,925
79
79
  strawberry/experimental/pydantic/error_type.py,sha256=RdmiUY4V0baXCAk80ST-XtCiZbndZaaUSEajQplDAzw,4557
80
80
  strawberry/experimental/pydantic/exceptions.py,sha256=pDMPL94ojuSGHxk8H8mI2pfWReG8BhqZ5T2eSxfOi9w,1486
@@ -228,8 +228,8 @@ strawberry/utils/logging.py,sha256=U1cseHGquN09YFhFmRkiphfASKCyK0HUZREImPgVb0c,7
228
228
  strawberry/utils/operation.py,sha256=s7ajvLg_q6v2mg47kEMQPjO_J-XluMKTCwo4d47mGvE,1195
229
229
  strawberry/utils/str_converters.py,sha256=-eH1Cl16IO_wrBlsGM-km4IY0IKsjhjnSNGRGOwQjVM,897
230
230
  strawberry/utils/typing.py,sha256=Xmnhwvnw8RIQVIc5D5iI4_9qM4Thpk7tWx8xf-RW_So,13383
231
- strawberry_graphql-0.264.0.dist-info/LICENSE,sha256=m-XnIVUKqlG_AWnfi9NReh9JfKhYOB-gJfKE45WM1W8,1072
232
- strawberry_graphql-0.264.0.dist-info/METADATA,sha256=Z4gLrc-diDadDxYz17PQW1OIjVnLJ-qwQjIJQSkLYO0,7679
233
- strawberry_graphql-0.264.0.dist-info/WHEEL,sha256=fGIA9gx4Qxk2KDKeNJCbOEwSrmLtjWCwzBz351GyrPQ,88
234
- strawberry_graphql-0.264.0.dist-info/entry_points.txt,sha256=Nk7-aT3_uEwCgyqtHESV9H6Mc31cK-VAvhnQNTzTb4k,49
235
- strawberry_graphql-0.264.0.dist-info/RECORD,,
231
+ strawberry_graphql-0.264.1.dist-info/LICENSE,sha256=m-XnIVUKqlG_AWnfi9NReh9JfKhYOB-gJfKE45WM1W8,1072
232
+ strawberry_graphql-0.264.1.dist-info/METADATA,sha256=yzBQYwGKVGbceuco5ntoakRqb6DHT-RPTbBXZPhlPqc,7679
233
+ strawberry_graphql-0.264.1.dist-info/WHEEL,sha256=fGIA9gx4Qxk2KDKeNJCbOEwSrmLtjWCwzBz351GyrPQ,88
234
+ strawberry_graphql-0.264.1.dist-info/entry_points.txt,sha256=Nk7-aT3_uEwCgyqtHESV9H6Mc31cK-VAvhnQNTzTb4k,49
235
+ strawberry_graphql-0.264.1.dist-info/RECORD,,