You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For data models have values in ‘name’ and ‘description’ fields these fields would be cleared up if these parameters are not specified in DataModelApply.
These code will clear name and description values (if ‘myDataModel’ had them):
data_models = [DataModelApply(space="mySpace",external_id="myDataModel",version="v1")] c.data_modeling.data_models.apply(data_models)
These code won’t clear name and description values (if ‘myDataModel’ had them):
Two things here on the question
First, the two code snippets are identical, so I do not understand why the first clears name and description and the second don't.
The solution seems like a contradiction:
Set ‘name’ as required for DataModelApply.
Fix clearing values from name and description in DataModelApply when these parameters are not specified.
You cannot require name (1.) and not 'clear' values when name is not specified (2.)
Answer.
First, this seems to be an issue of the API and not the SDK. When you set name and description to None, the SDK does not send them when you call the apply methdod
Second, the SDK is not an application like the UI is. It is a tool for developers and I do not think the SDK should put an extra restriction on the name parameter and make it required when the API has it as optional.
First name is not required and thus should be optional.
Second, the updating of description and name works as expected. If you set the them to any value including None in an existing model, they will be updated.
The text was updated successfully, but these errors were encountered: