Skip to content

Conversation

@neoneo40
Copy link
Contributor

I tried to fix UnicodeDecodeError with my valuable a lot of time.
The other people will have to save the time.
Thank you.

p.s: This is My first Pull Request :D

@wrichert
Copy link
Collaborator

Thanks, @re4lfl0w. Did you use Python 2.7 or 3?

@neoneo40
Copy link
ContributorAuthor

I use Python 2.7 :D
I know now I realize your question meaning.
Python 3.0 default character set is utf-8.

fromplatformimportpython_versionifpython_version().startswith('2'): text=text.decode('utf-8')

wrichert added a commit that referenced this pull request Feb 3, 2015
Modify UnicodeDecodeError text. Use utf-8 in case of Python version is 2.x.
@wrichertwrichert merged commit e1d2b6d into luispedro:masterFeb 3, 2015
@wrichert
Copy link
Collaborator

Thanks, @re4lfl0w!

Just in case you have questions directly to the book itself, feel free to ask them at http://twotoreal.com/u/wr/4/building-machine-learning-systems-in-python/ :-)

Sign up for freeto 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

@neoneo40@wrichert