strawberry-graphql 0.226.0__py3-none-any.whl → 0.226.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.
- strawberry/ext/mypy_plugin.py +12 -1
- {strawberry_graphql-0.226.0.dist-info → strawberry_graphql-0.226.1.dist-info}/METADATA +1 -1
- {strawberry_graphql-0.226.0.dist-info → strawberry_graphql-0.226.1.dist-info}/RECORD +6 -6
- {strawberry_graphql-0.226.0.dist-info → strawberry_graphql-0.226.1.dist-info}/LICENSE +0 -0
- {strawberry_graphql-0.226.0.dist-info → strawberry_graphql-0.226.1.dist-info}/WHEEL +0 -0
- {strawberry_graphql-0.226.0.dist-info → strawberry_graphql-0.226.1.dist-info}/entry_points.txt +0 -0
strawberry/ext/mypy_plugin.py
CHANGED
@@ -487,12 +487,23 @@ def strawberry_pydantic_class_callback(ctx: ClassDefContext) -> None:
|
|
487
487
|
initializer=None,
|
488
488
|
kind=ARG_OPT,
|
489
489
|
)
|
490
|
+
extra_type = ctx.api.named_type(
|
491
|
+
"builtins.dict",
|
492
|
+
[ctx.api.named_type("builtins.str"), AnyType(TypeOfAny.explicit)],
|
493
|
+
)
|
494
|
+
|
495
|
+
extra_argument = Argument(
|
496
|
+
variable=Var(name="extra", type=UnionType([NoneType(), extra_type])),
|
497
|
+
type_annotation=UnionType([NoneType(), extra_type]),
|
498
|
+
initializer=None,
|
499
|
+
kind=ARG_OPT,
|
500
|
+
)
|
490
501
|
|
491
502
|
add_static_method_to_class(
|
492
503
|
ctx.api,
|
493
504
|
ctx.cls,
|
494
505
|
name="from_pydantic",
|
495
|
-
args=[model_argument],
|
506
|
+
args=[model_argument, extra_argument],
|
496
507
|
return_type=fill_typevars(ctx.cls.info),
|
497
508
|
)
|
498
509
|
|
@@ -96,7 +96,7 @@ strawberry/ext/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
96
96
|
strawberry/ext/dataclasses/LICENSE,sha256=WZgm35K_3NJwLqxpEHJJi7CWxVrwTumEz5D3Dtd7WnA,13925
|
97
97
|
strawberry/ext/dataclasses/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
98
98
|
strawberry/ext/dataclasses/dataclasses.py,sha256=Le32f96qmahuenVsMW5xjIr-EPnO7WKljbOPLpU800Q,2254
|
99
|
-
strawberry/ext/mypy_plugin.py,sha256=
|
99
|
+
strawberry/ext/mypy_plugin.py,sha256=VdeNIrV6jVV-2xepneo0TNFI7wWfjTGAcLHxARzxRTw,19380
|
100
100
|
strawberry/extensions/__init__.py,sha256=SZ-YEMnxAzoDZFo-uHXMHOaY_PPkYm1muPpK4ccJ3Xk,1248
|
101
101
|
strawberry/extensions/add_validation_rules.py,sha256=l1cCl6VGQ8c2EELK3cIjmn6RftonHD1jKoWQ5-hMTf0,1366
|
102
102
|
strawberry/extensions/base_extension.py,sha256=XvYKIsSaxfTCVWdphOFll-Fo0wJd5Ib4QdKuYule6S0,2000
|
@@ -241,8 +241,8 @@ strawberry/utils/logging.py,sha256=flS7hV0JiIOEdXcrIjda4WyIWix86cpHHFNJL8gl1y4,7
|
|
241
241
|
strawberry/utils/operation.py,sha256=Um-tBCPl3_bVFN2Ph7o1mnrxfxBes4HFCj6T0x4kZxE,1135
|
242
242
|
strawberry/utils/str_converters.py,sha256=avIgPVLg98vZH9mA2lhzVdyyjqzLsK2NdBw9mJQ02Xk,813
|
243
243
|
strawberry/utils/typing.py,sha256=Qxz1LwyVsNGV7LQW1dFsaUbsswj5LHBOdKLMom5eyEA,13491
|
244
|
-
strawberry_graphql-0.226.
|
245
|
-
strawberry_graphql-0.226.
|
246
|
-
strawberry_graphql-0.226.
|
247
|
-
strawberry_graphql-0.226.
|
248
|
-
strawberry_graphql-0.226.
|
244
|
+
strawberry_graphql-0.226.1.dist-info/LICENSE,sha256=m-XnIVUKqlG_AWnfi9NReh9JfKhYOB-gJfKE45WM1W8,1072
|
245
|
+
strawberry_graphql-0.226.1.dist-info/METADATA,sha256=bbV0w8Q9lfWBuPg0AQY07CpZMXxiH5jvpQ00RephDj0,7740
|
246
|
+
strawberry_graphql-0.226.1.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
247
|
+
strawberry_graphql-0.226.1.dist-info/entry_points.txt,sha256=Nk7-aT3_uEwCgyqtHESV9H6Mc31cK-VAvhnQNTzTb4k,49
|
248
|
+
strawberry_graphql-0.226.1.dist-info/RECORD,,
|
File without changes
|
File without changes
|
{strawberry_graphql-0.226.0.dist-info → strawberry_graphql-0.226.1.dist-info}/entry_points.txt
RENAMED
File without changes
|