I am trying to write a python scraper using beautifulsoup. I successfully extracted most of the data, but I am facing now an encoding problem in the price extraction.
Here is my example:
The actual text is 1599€99
The scrapped text is:
>>>prdt.find("span",{"class":"price"}).text
u'1599\u20ac99'
"\u20ac" is supposed to be the '€' symbol using UTF-8 encoding however:
>>>prdt.find("span",{"class":"price"}).text.encode(encoding='UTF-8')
'1599\xe2\x82\xac99'
Does anyone know how to fix this issue?
Thanks.