PythonGenerator with Pydantic If a property is Optional not required the json expected a key None #1644
Labels
bug
Something isn't working
good first issue
Good for newcomers
Python generator
Anything related to the Python generator
released on @next
released
Describe the bug
PythonGenerator with Pydantic
How to Reproduce
If a property is Optional not required the json expected a key None
it is possible change the Class Python pydantic generator and add a default value =None for not required properties
from:
optionalkey: Optional[str] = Field( )
to:
optionalkey: Optional[str] = Field( default= None )
The text was updated successfully, but these errors were encountered: