pylixm / django-mdeditor

Django-mdeditor is Markdown Editor plugin application for django base on Editor.md.
https://pypi.org/project/django-mdeditor/
GNU General Public License v3.0
485 stars 109 forks source link

0.1.17 Windows10下安装错误 #72

Closed liutianfang closed 4 years ago

liutianfang commented 4 years ago

错误信息: File "C:\Users\xxx\AppData\Local\Temp\pip-install-yg2zdab3\django-mdeditor\setup.py", line 5, in long_description = readme.read() UnicodeDecodeError: 'gbk' codec can't decode byte 0xad in position 167: illegal multibyte sequence

修改建议:

with open(os.path.join(os.path.dirname(__file__), 'README.md')) as readme:

to:

with open(os.path.join(os.path.dirname(__file__), 'README.md'), 'rb') as readme: 

with open(os.path.join(os.path.dirname(__file__), 'README.md'), , encoding='UTF-8') as readme:
ameng404 commented 4 years ago

建议修改,我也遇到这个错误了

ameng404 commented 4 years ago

错误信息: File "C:\Users\xxx\AppData\Local\Temp\pip-install-yg2zdab3\django-mdeditor\setup.py", line 5, in long_description = readme.read() UnicodeDecodeError: 'gbk' codec can't decode byte 0xad in position 167: illegal multibyte sequence

修改建议:

with open(os.path.join(os.path.dirname(__file__), 'README.md')) as readme:

to:

with open(os.path.join(os.path.dirname(__file__), 'README.md'), 'rb') as readme: 

with open(os.path.join(os.path.dirname(__file__), 'README.md'), , encoding='UTF-8') as readme:

建议退0.1.16 ,亲测有效

pylixm commented 4 years ago

这个地方 python3 和python2 有冲突,我抽空做下适配,感谢 @liutianfang 和 @Ameng404 建议,可根据自己使用python版本,酌情修改来修复安装问题。

szdytom commented 4 years ago

现在可以下载.tar.gz源代码包,手动加encoding改错然后python setup.py install安装。

pylixm commented 4 years ago

已修复