You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "foo.py", line 19, in <module>
response = client.search('San Francisco', term=u'aü')
File "/nail/home/kmitton/pg/other/yelp-python/yelp/endpoint/search.py", line 44, in search
self.client._make_request(SEARCH_PATH, url_params)
File "/nail/home/kmitton/pg/other/yelp-python/yelp/client.py", line 47, in _make_request
signed_url = self.authenticator.sign_request(url, url_params)
File "/nail/home/kmitton/pg/other/yelp-python/yelp/oauth1_authenticator.py", line 36, in sign_request
return oauth_request.to_url()
File "/nail/home/kmitton/pg/kmitton-bash/virtualenv_run/lib/python2.7/site-packages/oauth2/__init__.py", line 363, in to_url
urllib.urlencode(query, True), fragment)
File "/usr/lib64/python2.7/urllib.py", line 1354, in urlencode
l.append(k + '=' + quote_plus(str(elt)))
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 1: ordinal not in range(128)
I'd expect Search to take Unicode objects in Python 2.7:
It fails:
Workaround: Manually encode as UTF-8 bytestring:
Feels like we should be able to handle Unicode.
The text was updated successfully, but these errors were encountered: