Regression 38.7.0: ascii decode error when installing package from source
See original GitHub issueWhen installing https://github.com/file/file/blob/master/python/ from source python 2.7.14 setuptools 38.7.0 fails:
Traceback (most recent call last):
File "setup.py", line 21, in <module>
'Topic :: Software Development :: Libraries :: Python Modules',
File "/home/asavah/kross/host/lib/python2.7/site-packages/setuptools-38.7.0-py2.7.egg/setuptools/__init__.py", line 129, in setup
return distutils.core.setup(**attrs)
File "/home/asavah/kross/host/lib/python2.7/distutils/core.py", line 151, in setup
dist.run_commands()
File "/home/asavah/kross/host/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/home/asavah/kross/host/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/home/asavah/kross/host/lib/python2.7/site-packages/setuptools-38.7.0-py2.7.egg/setuptools/command/install.py", line 69, in run
self.do_egg_install()
File "/home/asavah/kross/host/lib/python2.7/site-packages/setuptools-38.7.0-py2.7.egg/setuptools/command/install.py", line 111, in do_egg_install
self.run_command('bdist_egg')
File "/home/asavah/kross/host/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/home/asavah/kross/host/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/home/asavah/kross/host/lib/python2.7/site-packages/setuptools-38.7.0-py2.7.egg/setuptools/command/bdist_egg.py", line 163, in run
self.run_command("egg_info")
File "/home/asavah/kross/host/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/home/asavah/kross/host/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/home/asavah/kross/host/lib/python2.7/site-packages/setuptools-38.7.0-py2.7.egg/setuptools/command/egg_info.py", line 271, in run
writer(self, ep.name, os.path.join(self.egg_info, ep.name))
File "/home/asavah/kross/host/lib/python2.7/site-packages/setuptools-38.7.0-py2.7.egg/setuptools/command/egg_info.py", line 604, in write_pkg_info
metadata.write_pkg_info(cmd.egg_info)
File "/home/asavah/kross/host/lib/python2.7/distutils/dist.py", line 1106, in write_pkg_info
self.write_pkg_file(pkg_info)
File "/home/asavah/kross/host/lib/python2.7/site-packages/setuptools-38.7.0-py2.7.egg/setuptools/dist.py", line 76, in write_pkg_file
file.write('%s: %s\n' % (field, attr_val))
UnicodeEncodeError: 'ascii' codec can't encode character u'\xc1' in position 23: ordinal not in range(128)
Setuptools 38.6.0 works fine.
Edit: python 3.6.4 + setuptools 38.7.0 also works fine.
Issue Analytics
- State:
- Created 6 years ago
- Comments:8 (6 by maintainers)
Top Results From Across the Web
'ascii' codec can't decode error when use pip to install uwsgi
I HAVE FOUND THE RIGHT ANSWER! It is because when Python installs some packages, it will check the Windows Registry, some Chinese software...
Read more >setuptools 4.0 - PyPI
Easily download, build, install, upgrade, and uninstall Python packages.
Read more >Meaning of common message when install a package "There ...
This often means that the package has updated recently on CRAN but the binary isn't yet available for your OS (can take a...
Read more >python3 setup unicode error - Google Groups
UnicodeDecodeError : 'ascii' codec can't decode byte 0xc3 in position 2092: ordinal not in range(128) Complete output from command python setup.py egg_info:
Read more >Installing scikit-learn
When using pip, please ensure that binary wheels are used, and NumPy and SciPy are not recompiled from source, which can happen when...
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 FreeTop 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
Top GitHub Comments
Found the problem. On Python 2.7 there is an
_encode_field
function that is called inget_contact()
, but I was looking at the current master branch’s implementation and couldn’t understand what was going on. PR incoming.Release going out as v39.0.1. Please test and report back if a backport to v38 is required.