graphene-pydantic icon indicating copy to clipboard operation
graphene-pydantic copied to clipboard

TypeError: Registry.register_object_field() got an unexpected keyword argument 'model'

Open c-xlenz opened this issue 1 year ago • 2 comments

when trying to build a model, I am getting the error:

TypeError: Registry.register_object_field() got an unexpected keyword argument 'model'

checked the method and it does not have "model" as argument... so the error seems to be correct. The call of the method not. Any advice?

here is a minimalistic example:

´´´ class A(pydantic.BaseModel): x: str | None = None y: list["A"] | None = None

class P_A(PydanticInputObjectType): class Meta: model = A

P_A.resolve_placeholders() ´´´

c-xlenz avatar Nov 14 '24 12:11 c-xlenz

I think it is the same as here: https://github.com/graphql-python/graphene-pydantic/issues/104

c-xlenz avatar Nov 14 '24 12:11 c-xlenz

i answered here in https://github.com/graphql-python/graphene-pydantic/issues/104

iromanov-nk avatar Nov 22 '24 12:11 iromanov-nk