关于win安装django-aliyun-oss2-storage报错问题

win下报错信息为:

ERROR: Command errored out with exit status 1:
command: ‘c:\users\dell\appdata\local\programs\python\python36\python.exe’ -c ‘import io, os, sys, setuptools, tokenize; sys.argv[0] = ‘"’"‘C:\Users\Dell\AppData\Local\Temp\pip-install-7zza8mj8\django-aliyun-oss2-storage_6fef8ae8dbb64c7fb6a8f52dc1c98bef\setup.py’"’"’; file=’"’"‘C:\Users\Dell\AppD
ata\Local\Temp\pip-install-7zza8mj8\django-aliyun-oss2-storage_6fef8ae8dbb64c7fb6a8f52dc1c98bef\setup.py’"’"’;f = getattr(tokenize, ‘"’"‘open’"’"’, open)(file) if os.path.exists(file) else io.StringIO(’"’"‘from setuptools import setup; setup()’"’"’);code = f.read().replace(’"’"’\r\n’"’"’, ‘"’"’\n’"’"’
);f.close();exec(compile(code, file, ‘"’"‘exec’"’"’))’ egg_info --egg-base ‘C:\Users\Dell\AppData\Local\Temp\pip-pip-egg-info-bethyr08’
cwd: C:\Users\Dell\AppData\Local\Temp\pip-install-7zza8mj8\django-aliyun-oss2-storage_6fef8ae8dbb64c7fb6a8f52dc1c98bef
Complete output (5 lines):
Traceback (most recent call last):
File “”, line 1, in
File “C:\Users\Dell\AppData\Local\Temp\pip-install-7zza8mj8\django-aliyun-oss2-storage_6fef8ae8dbb64c7fb6a8f52dc1c98bef\setup.py”, line 5, in
README = readme.read()
UnicodeDecodeError: ‘gbk’ codec can’t decode byte 0x91 in position 63: illegal multibyte sequence

错误为:gbk decodeerror

setup.py”, line 5, in README = readme.read()
UnicodeDecodeError: ‘gbk’ codec can’t decode byte 0x91 in position 63: illegal multibyte sequence

查看setup.py文件 line 5: 默认decode

with open(os.path.join(os.path.dirname(file),‘README.md’)) as readme:
README = readme.read()

尝试指定:encoding="utf8”

with open(os.path.join(os.path.dirname(file),‘README.md’),encoding="utf8”) as readme:
README = readme.read()

手动安装:

python setup.py install

安装成功:

Finished processing dependencies for django-aliyun-oss2-storage==0.1.5

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值