salesforce-marketingcloud / FuelSDK-Python

FuelSDK for python
Other
126 stars 194 forks source link

[BUG] Data extension row creation fails when just Name is provided #119

Open vijayprakashpj opened 4 years ago

vijayprakashpj commented 4 years ago

Describe the bug The creation of data extension row fails when only Name attribute value is provided in the request payload as the underlying logic in self.getCustomerKey() method to describe and determine the CustomerKey's filter condition is incorrectly matching the Name attribute value with CustomerKey field of data extensions.

To Reproduce Initialize an ET_DataExtension_Row() object with the following attributes:

Expected behavior Name attribute value must be compared with the data extension name field instead of CustomerKey field.

Screenshots image

Code snippet

auto_suppression_entry = ET_DataExtension_Row()
auto_suppression_entry.auth_stub = client
# auto_suppression_entry.Name = "My Auto Suppression List"
auto_suppression_entry.CustomerKey = "00000000-0000-0000-0000-000000000000"
auto_suppression_entry.props = {
    "Email Address": "abc@gexample.com"
}
results = auto_suppression_entry.post()

Environment

The bug has the severity