mixpanel / mixpanel-utils

Other
87 stars 63 forks source link

csv exports fail for non-ascii distinct_ids #1

Closed cassiegamm closed 7 years ago

cassiegamm commented 7 years ago

csv exports fail for non-ascii distinct_ids with errors like: UnicodeEncodeError: 'ascii' codec can't encode character u'\xe4' in position 22: ordinal not in range(128)

to fix change https://github.com/mixpanel/mixpanel_api/blob/6d3fab496e1a01b83a59fb2d7bc72dd47c461af5/__init__.py#L1097 to

row.append(item[initial_header_value].encode('utf-8'))

jaredmixpanel commented 7 years ago

Thanks @cassiegamm - Fixed: https://github.com/mixpanel/mixpanel_api/commit/02d109515815eff719bff756e727aa74c3a03981