Skip to content

Commit 6c90347

Browse files
committed
Weird hacky fix
1 parent 872a404 commit 6c90347

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

graphene_pydantic/converters.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,10 @@ def convert_pydantic_field(
131131
# - maybe even (Sphinx-style) parse attribute documentation
132132
field_kwargs.setdefault("description", field.field_info.description)
133133

134+
# Somehow, this happens
135+
if "type_" not in field_kwargs and "type" in field_kwargs:
136+
field_kwargs["type_"] = field_kwargs.pop("type")
137+
134138
return Field(resolver=get_attr_resolver(field.name), **field_kwargs)
135139

136140

0 commit comments

Comments
 (0)