1、 pip install pipenv 安装Pipev时报错是因为我安装有python2和python3两个,选择如下的解决方式:
- python2 -m pip install xxx 或者
- python3 -m pip install xxx
2、pipenv install时出现如下错误:
call_subprocess(cmd, show_stdout=False, extra_env=env, stdin=script)
File "d:\soft_install\python3\python3.7\lib\site-packages\virtualenv.py", line 963, in call_subprocess
raise OSError("Command {} failed with error code {}".format(cmd_desc, proc.returncode))
OSError: Command
如上的解决方法如下:
- pipenv run pip3 install pip3==18.0
- pipenv install
3、pipenv install django==2.2.3总会出现如下超时错误:
解决方法是和换成国内源
国内源的选择:
- 阿里云:http://mirrors.aliyun.com/pypi/simple/
- 豆瓣:http://pypi.douban.com/simple/
- 清华大学:https://pypi.tuna.tsinghua.edu.cn/simple/
- 中国科学技术大学:https://pypi.mirrors.ustc.edu.cn/simple/
更换清华源,把Pipfile的url改成清华源:
[[source]]
url = "https://pypi.tuna.tsinghua.edu.cn/simple/"
verify_ssl = true
name = "pypi"
[packages]
flask = "*"
requests = "*"
wtforms = "*"
flask-sqlalchemy = "*"
cymysql = "*"
flask-login = "*"
[dev-packages]
[requires]
python_version = "3.7"