VelorumS f082a35d2e
[Python] fix object arrays giving mypy error "Incompatible types in assignment" in to_dict() (#19223)
* [python] mypy fix for multiple arrays of objects

* [python] mypy test for multiple arrays of objects
2024-07-29 16:34:27 +08:00

1010 B

MultiArrays

Properties

Name Type Description Notes
tags List[Tag] [optional]
files List[File] Another array of objects in addition to tags (mypy check to not to reuse the same iterator) [optional]

Example

from petstore_api.models.multi_arrays import MultiArrays

# TODO update the JSON string below
json = "{}"
# create an instance of MultiArrays from a JSON string
multi_arrays_instance = MultiArrays.from_json(json)
# print the JSON string representation of the object
print(MultiArrays.to_json())

# convert the object into a dict
multi_arrays_dict = multi_arrays_instance.to_dict()
# create an instance of MultiArrays from a dict
multi_arrays_from_dict = MultiArrays.from_dict(multi_arrays_dict)

[Back to Model list] [Back to API list] [Back to README]