Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 #2

Open
githubcom13 opened this issue Jul 14, 2018 · 0 comments
Open

UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 #2

githubcom13 opened this issue Jul 14, 2018 · 0 comments

Comments

@githubcom13
Copy link

githubcom13 commented Jul 14, 2018

If the result returns keywords with accents then there is a problem:

  • Running on http://127.0.0.1:80/ (Press CTRL+C to quit)
    127.0.0.1 - - [13/Jul/2018 22:43:39] "GET / HTTP/1.1" 200 -
    [2018-07-13 22:43:42,802] ERROR in app: Exception on /get_all_related/ecole [GET]
    Traceback (most recent call last):
    File "C:\Users\AppData\Local\Programs\Python\Python37-32\lib\site-packages\flask\app.py", line 1982, in wsgi_app
    response = self.full_dispatch_request()
    File "C:\Users\AppData\Local\Programs\Python\Python37-32\lib\site-packages\flask\app.py", line 1614, in full_dispatch_request
    rv = self.handle_user_exception(e)
    File "C:\Users\AppData\Local\Programs\Python\Python37-32\lib\site-packages\flask\app.py", line 1517, in handle_user_exception
    reraise(exc_type, exc_value, tb)
    File "C:\Users\AppData\Local\Programs\Python\Python37-32\lib\site-packages\flask_compat.py", line 33, in reraise
    raise value
    File "C:\Users\AppData\Local\Programs\Python\Python37-32\lib\site-packages\flask\app.py", line 1612, in full_dispatch_request
    rv = self.dispatch_request()
    File "C:\Users\AppData\Local\Programs\Python\Python37-32\lib\site-packages\flask\app.py", line 1598, in dispatch_request
    return self.view_functionsrule.endpoint
    File "C:\Users\Desktop\google_vs_graph\app.py", line 33, in get_all_related
    for related in get_related(entity):
    File "C:\Users\Desktop\google_vs_graph\app.py", line 20, in get_related
    suggestions = json.loads(result.read())
    File "C:\Users\AppData\Local\Programs\Python\Python37-32\lib\json_init_.py", line 343, in loads
    s = s.decode(detect_encoding(s), 'surrogatepass')
    UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 54: invalid continuation byte
    127.0.0.1 - - [13/Jul/2018 22:43:42] "GET /get_all_related/ecole HTTP/1.1" 500 -
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant