Celery: vine is not installed as part of the celery's requirements

Created on 5 Nov 2016  路  21Comments  路  Source: celery/celery

Checklist

  • [x] I have included the output of celery -A proj report in the issue.
    (if you are not able to do this, then at least specify the Celery
    version affected).
  • [ ] I have verified that the issue exists against the master branch of Celery.

Steps to reproduce

pip install celery

Then in python:

from celery import Celery

Expected behavior

Celery running fine.

Actual behavior

  File "/root/.virtualenvs/ceres/lib/python2.7/site-packages/celery/__init__.py", line 149, in <module>
    from . import local  # noqa
  File "/root/.virtualenvs/ceres/lib/python2.7/site-packages/celery/local.py", line 15, in <module>
    from .five import bytes_if_py2, items, string, string_t
  File "/root/.virtualenvs/ceres/lib/python2.7/site-packages/celery/five.py", line 5, in <module>
    import vine.five
ImportError: No module named vine.five

Most helpful comment

Please upgrade to 4.3.1.

All 21 comments

Just tried to reproduce on a fresh virtual environment:

$ pip install celery
Collecting celery
  Downloading celery-4.0.0-py2.py3-none-any.whl (395kB)
    100% |鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅| 399kB 1.7MB/s
Collecting kombu<5.0,>=4.0 (from celery)
  Downloading kombu-4.0.0-py2.py3-none-any.whl (178kB)
    100% |鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅| 184kB 2.8MB/s
Collecting pytz>dev (from celery)
  Downloading pytz-2016.7-py2.py3-none-any.whl (480kB)
    100% |鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅| 481kB 2.0MB/s
Collecting billiard<3.6.0,>=3.5.0.2 (from celery)
  Downloading billiard-3.5.0.2-py3-none-any.whl (102kB)
    100% |鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅| 102kB 3.0MB/s
Collecting amqp<3.0,>=2.1.1 (from kombu<5.0,>=4.0->celery)
  Downloading amqp-2.1.1-py2.py3-none-any.whl (48kB)
    100% |鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅鈻堚枅| 51kB 3.1MB/s
Collecting vine>=1.1.3 (from amqp<3.0,>=2.1.1->kombu<5.0,>=4.0->celery)
  Downloading vine-1.1.3-py2.py3-none-any.whl
Installing collected packages: vine, amqp, kombu, pytz, billiard, celery
Successfully installed amqp-2.1.1 billiard-3.5.0.2 celery-4.0.0 kombu-4.0.0 pytz-2016.7 vine-1.1.3

As you can see, vine is installing correctly.

I'm experiencing this now installing celery 4.0.2 in a Debian:jessie Docker container.

What's happening for me is that certain dependencies are not being installed when I include celery as a dependency of a Django project (in the project's setup.py). When I pip install that project (with celery just added to setup.py):
Successfully installed billiard-3.5.0.2 celery-4.0.2 pytz-2016.10
Then when I subsequently pip install celery, I get:
Installing collected packages: vine, amqp, kombu

Just happened to me. We're building with tox.

[2]   File "/home/jenkins/workspace/Warrior/wsomanager-rest-staging@4/.tox/test/local/lib/python2.7/site-packages/celery/__init__.py", line 149, in <module>
[2]     from . import local  # noqa
[2]   File "/home/jenkins/workspace/Warrior/wsomanager-rest-staging@4/.tox/test/local/lib/python2.7/site-packages/celery/local.py", line 15, in <module>
[2]     from .five import bytes_if_py2, items, string, string_t
[2]   File "/home/jenkins/workspace/Warrior/wsomanager-rest-staging@4/.tox/test/local/lib/python2.7/site-packages/celery/five.py", line 5, in <module>
[2]     import vine.five
[2] ImportError: No module named vine.five

setup.py

...
install_requires=[
    ...
    'celery==4.0.2',
    ...
]
...

@malinoff Do you not think this worth re-opening?

I'm willing to re-open and fix this issue, but only if I get the exact steps to reproduce,

Ok, I did some more digging and in our case the problem was actually that we had been specifying an older version of kombu in our setup.py before we added celery, and due to a limitation in pip (https://github.com/pypa/pip/issues/775), that conflict isn't detected and the older version was being installed instead of the one specified by celery. Sorry about that!
Hopefully that's of some help to you too @nmcalabroso?

running pip check is a nice shortcut to finding any conflicted versions based on the limitation of pip referenced by @mcgeeco

I ran into a similar problem by specifying an out-of-date version of amqp.

This "problem" typically happens when people pin dependencies to some old package... pip check is the way to find this problem and fix it.

Sorry, I didn't mean to indicate there was an issue here, just that I found the solution by reading this ticket and wanted to include the package that was causing my problem to help alleviate any future searcher's troubles.

I'm getting this error in a Raspberry Pi 3. I guess it's consequence of the errors I get when installing. Doesn't install completely on a RPi3

I got this error:

celery init v10.1.
Using config script: /etc/default/celeryd
Traceback (most recent call last):
  File "/usr/local/bin/celery", line 7, in <module>
    from celery.__main__ import main
  File "/usr/local/lib/python3.5/dist-packages/celery/__init__.py", line 150, in <module>
    from . import local  # noqa
  File "/usr/local/lib/python3.5/dist-packages/celery/local.py", line 17, in <module>
    from .five import PY3, bytes_if_py2, items, string, string_t
  File "/usr/local/lib/python3.5/dist-packages/celery/five.py", line 7, in <module>
    import vine.five
ImportError: No module named 'vine'

Hello,

today I had this issue with celery version 4.3.0

The problem was that celery was installing vine version 4.0.0 I think, but it works with version 1.3.0

Please upgrade to 4.3.1.

Upgrade to 4.3.1. worked for me.

This happened installing 5.0.0 on a fresh env as well

Please try again, I've yanked the offending Kombu versions.

Please try again, I've yanked the offending Kombu versions.

Thanks. I can麓t find your commit. Installing the dev version from master does not resolve this issue for me.

It doesn't???
Could something be wrong with your pip version?

So, now it worked. However it now fails due to "No module named 'celery.five'"

See #6369.

Was this page helpful?
0 / 5 - 0 ratings