Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

map varchar(n) to Field(..., max_length=n) when targeting a pydantic model type #48

Open
faccini-bs opened this issue Feb 15, 2023 · 0 comments
Assignees

Comments

@faccini-bs
Copy link

Is your feature request related to a problem? Please describe.
The pydantic BaseModel (as well as dataclasses) validate the data on instantiation

Describe the solution you'd like
starting from FIELD1 VARCHAR(256)
instead of generating field1: str generate field1: str = Field(..., max_length=256)

Additional context
I like this project and think this is a step forward to make it more useful

@xnuinside xnuinside self-assigned this Mar 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants