无法导入Celery模块

ksi*_*elo 5 django celery django-celery

我有一个奇怪的问题,我成功安装芹菜,但我无法导入其模块:

>>> import celery   # OK

>>> import djcelery

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Library/Python/2.7/site-packages/django_celery-2.5.5-py2.7.egg/djcelery/__init__.py", line    25, in <module>
from celery import current_app as celery  # noqa
ImportError: cannot import name current_app

>>> from celery.decorators import task

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named decorators
Run Code Online (Sandbox Code Playgroud)

这个错误发生在芹菜2.6.0a3(来自github)或2.5.3(来自pypi)和django-celery 2.5.5上.尝试重新安装几次,甚至尝试在Jython中,我得到了同样的错误.

我不知道它是什么,任何人都可以帮助我吗?

ksi*_*elo -1

很好地从 github 克隆了项目(celery),并python setup.py install解决了。奇怪的是,当通过 pip 安装在我的机器上时,它无法导入其模块(即使 /Library/Python/2.7/site-packages/celery/decorators.py 任务在那里)。

希望它能帮助某人。