2010-11-29 86 views
0

我想弄清楚为什么我的Djagno wsgi脚本不会运行。它运行在正常的Python罚款的virtualenv产生以下堆栈跟踪:VirtualEnv无法导入名称包装

(virtualenv)... [~]# python djangosites/test1.wsgi 
Traceback (most recent call last): 
    File "djangosites/test1.wsgi", line 13, in <module> 
    from django.core.handlers.wsgi import WSGIHandler 
    File "/home/myofirst/virtualenv/lib/python2.6/site-packages/Django-1.2.3-py2.6.egg/django/core/handlers/wsgi.py", line 1, in <module> 
    from threading import Lock 
    File "/opt/python2.6/lib/python2.6/threading.py", line 13, in <module> 
    from functools import wraps 
ImportError: cannot import name wraps 

它看起来像我需要安装functools。我通过easy_install尝试了这一点,现在pip或easy_install都不会运行,他们都抱怨缺少wraps。我需要安装/卸载以解决此问题?

回答

1

创建一个新的virtualenv,因为这一个被打破。现在没问题。

+0

为了“关闭”问题,您应该接受此答案。 – 2010-11-29 04:20:37