创建新的 virtualenv 挂起
我有一台 macbookpro。
我从 pylonsbook.com/virutalenv.py 下载了 virtualenv.py,
当我输入:
python virtualenv.py --no-site-packages env
它输出:
New python executable in env/bin/python
然后它就挂起,我在终端中没有收到提示。
我重新启动计算机并得到相同的结果,这是怎么回事?
I have a macbookpro.
I downloaded virtualenv.py from pylonsbook.com/virutalenv.py
when I type:
python virtualenv.py --no-site-packages env
it outputs:
New python executable in env/bin/python
then it just hangs, I don't get the prompt in terminal.
I've restarted the computer and I get the same result, what's wrong?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
我知道我正在回答一个古老的问题,但这是谷歌中出现的第一件事,我花了两个小时调试它。我的 virtualenv 创建在之后停止
,我通过删除
~/.cached/pip/
修复了它。希望有帮助。I know I'm responding to an ancient question, but this is the first thing that came up in google and I spent two hours debugging it. My virtualenv creation was stalling after
And I fixed it by deleting
~/.cached/pip/
. Hope that helps.您是否尝试过使用
easy_install virtualenv
来代替?获取最新版本绝不是一个坏主意。(此外,该链接是我的 MacBook 上的 WFM。在出现提示后,它会将 setuptools 安装到虚拟环境中。)
Have you tried to
easy_install virtualenv
instead? Getting the most updated version is never a bad idea.(Also, that link WFM on my MacBook. After that prompt it installs setuptools into the virtual environment.)
没有太多可用信息,但从我从您提供的详细信息中收集到的信息来看,它在安装 setuptools 之前挂起。 setuptools 是通过从互联网获取来安装的。如果无法获取它,它可能会挂起。尝试将 setuptools 与 virtualenv.py 放在同一文件夹中,然后创建虚拟环境。这可能会解决问题。
There is not much information available but from what I can gather from the details that you have provided, it hangs just before installing setuptools. Setuptools is installed by fetching it from internet. It can hang, if it is not able to fetch it. Try keeping setuptools in the same folder as virtualenv.py and then create virtual env. This may solve the issue.
我刚刚下载了您正在使用的版本,按照您所做的那样输入命令,然后它挂起:
但只持续了三秒钟:
我从 http://pypi.python.org/pypi/virtualenv 根本没有挂起:
我不确定你在放弃之前等了多久。我会尝试从 python.org 安装该版本,看看该版本是否更适合您。
I just downloaded the version you are using, put the command in exactly as you did and it hung after:
But only for three seconds:
The installed the (easy_install) version I got from http://pypi.python.org/pypi/virtualenv did not hang at all:
I'm not sure how long you waited before giving up. I would try installing the version from python.org to see if that one works better for you.