import pydantic
from pydantic.experimental.missing_sentinel import MISSING
class UpdateUserPayload(pydantic.BaseModel):
phone_number: str | MISSING = MISSING
# Errors with "Expected a type form, got instance of `type[str] | UnionType`". Should not error.
Describe the Bug
This is an experimental feature, but required if you have a
PATCHmodel and the generated schema shouldn't erroneously indicate that the value is nullable.https://pydantic.dev/docs/validation/latest/concepts/experimental/#missing-sentinel
Sandbox Link
No response
(Only applicable for extension issues) IDE Information
No response