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

Add option to disable Field constraints

Open harrymconner opened this issue 8 months ago • 1 comments

Is your feature request related to a problem? Please describe. I'm in the unfortunate position of having to consume an API that has incorrect constraints in its OpenAPI documentation. Up until now, I have been manually removing the Field constraints, but I was wondering if this could be a useful CLI flag for anyone else.

Describe the solution you'd like Some sort of --no-constraints flag added as a CLI flag

Describe alternatives you've considered N/A

Additional context N/A

harrymconner avatar Mar 20 '25 19:03 harrymconner

I don't know how much sense it would have.

What kind of model are you trying to generate? Pydantic?

ilovelinux avatar Mar 21 '25 15:03 ilovelinux