Encoding issue

31 views
Skip to first unread message

Iván García

unread,
Apr 28, 2021, 12:50:47 PM4/28/21
to Eventbrite Developers
Hi all,

We have found a strange situation with special characters like the following ones: éáíóú. We are retrieving the information about one order, using the endpoint:


The information about the order contact is returning those characters in their corresponding unicodes:
  • U+00E9
  • U+00E1
  • U+00ED
  • U+00F3
  • U+00FA
But in the contact information of the attendees those characters are being convertend in the a simple character followed by the accent mark.
  • aU+0301
  • eU+0301
  • iU+0301
  • oU+0301
  • uU+0301
I do not know why this conversion is done. I think that is wrong, but what is most strange is why this is not working in the same way for attendees data and orders data.

Has anyone notice this? Is this the expected behaviour?

Regards

Eventbrite Developers

unread,
Apr 28, 2021, 2:57:30 PM4/28/21
to Eventbrite Developers
Hi Iván,

Thanks for reaching out. We've tested your call in Postman and are seeing the data return including the special characters without any change or conversion. This appears to be a formatting issue with your data store and how it is interpreting the data being retrieved. 

It has helped developers in the past to use JSON.parse directly on JSON response, then the unicode characters will automatically be converted to their html counterparts. Hope this is helpful. 

Best,
Donna

Iván García

unread,
Apr 29, 2021, 3:27:33 AM4/29/21
to Eventbrite Developers
Hi Donna,

I have done a request with Postman to test what you are saying, but it seems that is not working as you say. Not for me at least. I'm going to share with you the steps I have follow to detect the issue.

Step 1.
Launch the request in Postman: I share the results

EventBriteEncodingIssue1.png

As you can see the line 38 seems to contain the same text as the line 98. 
  • Line 38: "name": "Iván García García",
  • Line 98: "name": "Iván García García",

Step 2. 
But if you compare both string with some comparison tool, you can see that they are different.

EventBriteEncodingIssue2b.png

Step 3.
Convert to unicode to check how different are both strings:
  • Line 38: "name": "IvU+00E1n GarcU+00EDa GarcU+00EDa",
  • Line 98: "name": "IvaU+0301n GarciU+0301a GarciU+0301a",

As you can see, they really are not the same string, this as a first sight is not a problem, but if you are making some kind of comparison is not working as expected. 

So IMHO , both names should be completely equals (because I have inserted the same values in the registration form).

Regards.
Reply all
Reply to author
Forward
0 new messages