[BUG] `original_field` is not supported by pydantic, makes typecheckers give a type error and causes a warning at runtime
ldorigo opened this issue · 4 comments
ldorigo commented
Not much to add - e.g.:
class Foo(Document):
bar: Link[Bar]
class Bar(Document):
foos: list[BackLink[Foo]] = Field(original_field="bar")
IterableTrucks commented
original_field should be declared in the json_schema_extra
dictionary in pydantic v2 models. The documentation has not been updated. You can refer to this issue #885 (comment)
github-actions commented
This issue is stale because it has been open 30 days with no activity.
ldorigo commented
Not stale, fix the docs :)
github-actions commented
This issue is stale because it has been open 30 days with no activity.