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

UnicodeEncodeError: 'utf-8' codec can't encode character '\udcc3' in position 60: surrogates not allowed #207

Closed
dvska opened this issue Dec 26, 2014 · 5 comments
Labels

Comments

@dvska
Copy link

dvska commented Dec 26, 2014

            resp = yield from asyncio.wait_for(aiohttp.request('get', 'http://www.last.fm/user/gloriakitsune/journal/2014/04/24/61zejp_%5C%5Co_j%27y_%C3%A9tais_o', headers={
                'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:34.0) Gecko/20100101 Firefox/34.0',
                "Accept-Language": "fr"}, connector=self.get_connector(self.loop)), 60) 

UnicodeEncodeError: 'utf-8' codec can't encode character '\udcc3' in position 60: surrogates not allowed

@fafhrd91
Copy link
Member

@dvska this is fixed in master.

@asvetlov i changed encoding to utf8 for decoding http message, that is against spec, but it should be safe. what do you think?

@dvska
Copy link
Author

dvska commented Dec 27, 2014

Thanks, Nikolay!

@asvetlov
Copy link
Member

@fafhrd91 I don't know.

Seems like fix solves the issue. Let's live with that until we found new problem.

@asvetlov
Copy link
Member

266b386

@lock
Copy link

lock bot commented Oct 29, 2019

This thread has been automatically locked since there has not been
any recent activity after it was closed. Please open a new issue for
related bugs.

If you feel like there's important points made in this discussion,
please include those exceprts into that new issue.

@lock lock bot added the outdated label Oct 29, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Oct 29, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants