UnicodeEncodeError: 'ascii' codec can't encode characters in position 49-51: ordinal not in range(128) ()
See original GitHub issueLocale is en_US.UTF-8, python is 2.6.5
Same problem as the other one posted here, but my locale is set correctly. It printed 1 wow
user@host:~$ doge
wow
Traceback (most recent call last):
File "/usr/local/lib/python2.6/dist-packages/doge/core.py", line 396, in main
shibe.print_doge()
File "/usr/local/lib/python2.6/dist-packages/doge/core.py", line 245, in print_doge
sys.stdout.write(line)
UnicodeEncodeError: 'ascii' codec can't encode characters in position 49-51: ordinal not in range(128)
()
wow error: Unknown unicode error.
Issue Analytics
- State:
- Created 10 years ago
- Comments:12 (5 by maintainers)
Top Results From Across the Web
UnicodeEncodeError: 'ascii' codec can't encode character u ...
The issue is that when you call str(), python uses the default character encoding to try and encode the bytes you gave it,...
Read more >Fix Python UnicodeEncodeError: 'ascii' codec can't encode ...
A very common Python error that is raised when working with unicode characters is the UnicodeEncodeError . UnicodeEncodeError: 'ascii' codec can ...
Read more >UnicodeEncodeError 'ascii' 'ordinal not in range(128)'
- use .encode() or .decode() function but I get a very annoying message: An error occurred while processing the action acknowledgement.
Read more >'ascii' codec can't encode character '\xe9' in position ... - GitHub
UnicodeEncodeError : 'ascii' codec can't encode character '\xe9' in position 117: ordinal not in range(128) #10604.
Read more >Python UnicodeEncodeError: 'ascii' codec can't encode ...
This error occurs when you pass a Unicode string containing non-English characters (Unicode characters beyond 128) to something that expects an ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Changing it to
decode
fails, but changing it toencode
worked perfectly. For anyone that finds this in the future with this issue, here is a screenshot of line 245: http://i.imgur.com/IEAqBlw.pngWorks perfectly, few unsupported characters, but I should be able to fix that once I’m on a computer http://i.imgur.com/AS5GfaV.png
Sounds good! Much welcome!