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 error when building packages with python 3 #56

Closed
ghost opened this issue Jul 29, 2013 · 4 comments
Closed

UnicodeDecodeError error when building packages with python 3 #56

ghost opened this issue Jul 29, 2013 · 4 comments

Comments

@ghost
Copy link

ghost commented Jul 29, 2013

Originally reported by: iElectric (Bitbucket: iElectric, GitHub: Unknown)


#!python

Running setup.py -q bdist_egg --dist-dir /tmp/nix-build-python3.3-dateutil-2.1.drv-0/python-dateutil-2.1/egg-dist-tmp-wc9aoj
Traceback (most recent call last):
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/bin/.easy_install-wrapped", line 9, in <module>
    load_entry_point('setuptools==0.9.8', 'console_scripts', 'easy_install')()
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 1992, in main
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 1979, in with_ei_usage
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 1996, in <lambda>
  File "/nix/store/wsdh5dkcvfsl79q9v25kngcb0dpqja5w-python-offline-distutils-3.3.2/lib/python3.3/site-packages/distutils/core.py", line 148, in setup
    dist.run_commands()
  File "/nix/store/wsdh5dkcvfsl79q9v25kngcb0dpqja5w-python-offline-distutils-3.3.2/lib/python3.3/site-packages/distutils/dist.py", line 929, in run_commands
    self.run_command(cmd)
  File "/nix/store/wsdh5dkcvfsl79q9v25kngcb0dpqja5w-python-offline-distutils-3.3.2/lib/python3.3/site-packages/distutils/dist.py", line 948, in run_command
    cmd_obj.run()
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 380, in run
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 604, in easy_install
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 653, in install_item
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 849, in install_eggs
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 1130, in build_and_install
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/command/easy_install.py", line 1115, in run_setup
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/sandbox.py", line 69, in run_setup
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/sandbox.py", line 120, in run
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/sandbox.py", line 71, in <lambda>
  File "/nix/store/y6np826y0n0jkkqh3z27l1dang78jm34-python3.3m-setuptools-0.9.8/lib/python3.3/site-packages/setuptools-0.9.8-py3.3.egg/setuptools/compat.py", line 92, in execfile
  File "setup.py", line 16, in <module>
    open(TOPDIR + "/dateutil/__init__.py").read()).group(1)
  File "/nix/store/fbrjq023g4r3pm91irqb915xnwdzj1wv-python3-3.3.2/lib/python3.3/encodings/ascii.py", line 26, in decode
    return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 193: ordinal not in range(128)

@ghost
Copy link
Author

ghost commented Jul 29, 2013

Original comment by arfrever (Bitbucket: arfrever, GitHub: arfrever):


The traceback shows that problem is caused by open(...).read() call in setup.py of python-dateutil-2.1, which reads content of a file containing bytes not decodable using encoding corresponding to current locale. This is a bug in python-dateutil-2.1.

@ghost
Copy link
Author

ghost commented Oct 16, 2013

Original comment by ajung (Bitbucket: ajung, GitHub: ajung):


This error can not be invalid...it happens also on three different Linux boxes during the installation under Python 3.3....we don't not have to adjust the locale here. The installation is broken for whatever reason and it must be fixed in python-datetutil.

@ghost
Copy link
Author

ghost commented Oct 16, 2013

Original comment by ajung (Bitbucket: ajung, GitHub: ajung):


#!text

Downloading/unpacking python-dateutil==2.1
  Downloading python-dateutil-2.1.tar.gz (152kB): 152kB downloaded
  Running setup.py egg_info for package python-dateutil
    Traceback (most recent call last):
      File "<string>", line 16, in <module>
      File "/private/tmp/pp.server/build/python-dateutil/setup.py", line 16, in <module>
        open(TOPDIR + "/dateutil/__init__.py").read()).group(1)
      File "/private/tmp/pp.server/lib/python3.3/encodings/ascii.py", line 26, in decode
        return codecs.ascii_decode(input, self.errors)[0]
    UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 193: ordinal not in range(128)
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):

  File "<string>", line 16, in <module>

  File "/private/tmp/pp.server/build/python-dateutil/setup.py", line 16, in <module>

    open(TOPDIR + "/dateutil/__init__.py").read()).group(1)

  File "/private/tmp/pp.server/lib/python3.3/encodings/ascii.py", line 26, in decode

    return codecs.ascii_decode(input, self.errors)[0]

UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 193: ordinal not in range(128)

@ghost
Copy link
Author

ghost commented Oct 16, 2013

Original comment by arfrever (Bitbucket: arfrever, GitHub: arfrever):


This is bug tracker of Setuptools, not python-dateutil.

See python-dateutil bug 1208910.

@ghost ghost added major bug labels Mar 29, 2016
@ghost ghost closed this as completed Mar 29, 2016
jiongle1 pushed a commit to scantist-ossops-m2/setuptools that referenced this issue Apr 9, 2024
Script files to be copied in the develop command should be open in binary mode. Fixes pypa#210.
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

0 participants