datamodel-code-generator icon indicating copy to clipboard operation
datamodel-code-generator copied to clipboard

Timestamp with timezone format string type is generated as a string property of the pydantic model

Open dreinon opened this issue 3 years ago • 2 comments
trafficstars

Fields with schema

schema:
        type: string
        format: timestamp with time zone

are generated as string properties of the pydantic models instead of being generated as a datetime property, whereas

schema:
        type: string
        format: date

is correctly generated as date.

dreinon avatar Dec 01 '21 12:12 dreinon

@dreinon I'm sorry for my late response.

Yes, the code-generator has not supported the timestamp with time zone format. I will add the feature.

koxudaxi avatar Jan 11 '22 17:01 koxudaxi

No worries, thanks! @koxudaxi

dreinon avatar Jan 11 '22 17:01 dreinon