MacOS 10.12.6 新建虚拟环境mkvirtualenv mxonline 报错
来源:4-1 开发环境搭建指南-mac
慕粉0112268390
2020-01-20
MacOS 10.12.6
新建虚拟环境
mkvirtualenv mxonline
报错:
Using base prefix '/Library/Frameworks/Python.framework/Versions/3.7’
New python executable in /Users/agon/.virtualenvs/mxonline/bin/python3.7
Not overwriting existing python script /Users/agon/.virtualenvs/mxonline/bin/python (you must use /Users/agon/.virtualenvs/mxonline/bin/python3.7)
…Installing setuptools, pip, wheel…done.
Traceback (most recent call last):
File “/Library/Frameworks/Python.framework/Versions/3.7/bin/virtualenv”, line 8, in
sys.exit(main())
File “/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/virtualenv.py”, line 870, in main
symlink=options.symlink,
File “/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/virtualenv.py”, line 1179, in create_environment
install_wheel(to_install, py_executable, search_dirs, download=download)
File “/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/virtualenv.py”, line 1023, in install_wheel
_install_wheel_with_search_dir(download, project_names, py_executable, search_dirs)
File “/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/virtualenv.py”, line 1116, in _install_wheel_with_search_dir
call_subprocess(cmd, show_stdout=False, extra_env=env, stdin=script)
File “/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/virtualenv.py”, line 963, in call_subprocess
raise OSError(“Command {} failed with error code {}”.format(cmd_desc, proc.returncode))
OSError: Command /Users/agon/.virtual…online/bin/python3.7 - setuptools pip wheel failed with error code 2
1回答
-
bobby
2020-01-21
新建虚拟环境的时候 试试加上参数 --no-sit-packages --python=python3 然后再试试呢
00
相似问题