Python VirtualEnv无法导入名称包装

Python VirtualEnv无法导入名称包装,python,django,wsgi,Python,Django,Wsgi,我正在试图弄清楚为什么我的Djagno wsgi脚本无法运行。它在普通python下运行良好,但virtualenv生成以下堆栈跟踪: (virtualenv)... [~]# python djangosites/test1.wsgi Traceback (most recent call last): File "djangosites/test1.wsgi", line 13, in <module> from django.core.handlers.wsgi i

我正在试图弄清楚为什么我的Djagno wsgi脚本无法运行。它在普通python下运行良好,但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
(virtualenv)。。。[~]#python djangosites/test1.wsgi
回溯(最近一次呼叫最后一次):
文件“djangosites/test1.wsgi”,第13行,在
从django.core.handlers.wsgi导入WSGIHandler
文件“/home/myofirst/virtualenv/lib/python2.6/site packages/Django-1.2.3-py2.6.egg/Django/core/handlers/wsgi.py”,第1行,在
从线程导入锁
文件“/opt/python2.6/lib/python2.6/threading.py”,第13行,在
从functools导入包装
ImportError:无法导入名称包装

看起来我需要安装functools。我通过easy_install尝试了这一点,现在pip和easy_install都无法运行,它们都抱怨缺少
包装。我需要安装/卸载什么来修复此问题?

在此virtualenv损坏时创建了一个新的virtualenv。现在没有问题。

您应该接受此答案,以便“结束”问题。