BingAds / BingAds-Python-SDK

Other
118 stars 164 forks source link

BingAds Reporting API returns CSV with inconsistent encoding and CsvReader crashes #167

Closed peterKarkkainen closed 3 years ago

peterKarkkainen commented 4 years ago

Problem

Data in various columns of the .csv file returned by the BingAds Reporting API can be in different encoding. The SDK assumes it's all utf-8 by default (in case we are using Python3) - and errors out.

Example In our reports a word "Åhlens AB" would return as "\xc5hlens AB" (latin-1) when inside the CustomerName column and as "\xc3\x85hlens AB" (utf-8) when in the AccountName column of the same .csv file. The _CsvReader class of the SDK would attempt to read the line as utf-8-sig and fail.

qitia commented 3 years ago

thanks for reaching out and sorry for late reply. We confirm there is a bug at backend and will provide a fix soon. please expect it to be fixed before end of 2/26 UTC time.

AshishAgMS commented 3 years ago

This issue is fixed now.