Skip to content

Support date only type #89

Description

@tractorcow

Is your feature request related to a problem? Please describe.

When I am creating fields with type string, and format "date" I would like them to be typed as python datetime.date

"birth_date": {
	"type": "string",
	"format": "date"
},			

Describe the solution you'd like

Logic in type_converter when, with orjson enabled, types are generated as "datetime.date".

Describe alternatives you've considered

Potentially some other hooks or injectable logic inside type_converter that could allow a developer to inject or otherwise override type generation. This could be some kind of type registry.

Additional context
I am generating schema for date types that do not have time component, and would be incorrect to use datetime type.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions