I'm trying to do a translation with the api GoogleTrans ( link ). Code:
# -*- coding: utf-8 -*-
from googletrans import Translator
translator = Translator()
print translator.translate('hello', dest='pt')
I get the error:
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe1' in position 35:
ordinal not in range(128)
Can you help me with this question? I'm using PYTHON 2.7