Skip to content

add encoding for python 3.x#2

Merged
ztane merged 1 commit into
ztane:masterfrom
felixonmars:fix-py3
Feb 2, 2014
Merged

add encoding for python 3.x#2
ztane merged 1 commit into
ztane:masterfrom
felixonmars:fix-py3

Conversation

@felixonmars

Copy link
Copy Markdown

Installation with python 3.x will fail if command line encoding is not utf-8:

$ LANG=C python setup.py build
Traceback (most recent call last):
  File "setup.py", line 15, in <module>
    long_description=open("README.rst").read() + "\n" +
  File "/usr/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 1968: ordinal not in range(128)

This patch forced encoding to utf-8 if using python 3.x to install. Tried with python 2.7.6 and 3.3.3 and it works well.

ztane added a commit that referenced this pull request Feb 2, 2014
add encoding for python 3.x
@ztane ztane merged commit 64a8a50 into ztane:master Feb 2, 2014
@ztane

ztane commented Feb 2, 2014

Copy link
Copy Markdown
Owner

Thanks, merged.

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

Successfully merging this pull request may close these issues.

2 participants