__init__.py 850 B

1234567891011121314151617181920212223242526272829303132333435
  1. # -*- coding: utf-8 -*-
  2. """Distributed Task Queue"""
  3. # :copyright: (c) 2009 - 2012 by Ask Solem.
  4. # :license: BSD, see LICENSE for more details.
  5. from __future__ import absolute_import
  6. VERSION = (2, 5, 0, "rc2")
  7. __version__ = ".".join(map(str, VERSION[0:3])) + "".join(VERSION[3:])
  8. __author__ = "Ask Solem"
  9. __contact__ = "ask@celeryproject.org"
  10. __homepage__ = "http://celeryproject.org"
  11. __docformat__ = "restructuredtext"
  12. # -eof meta-
  13. import sys
  14. if sys.version_info < (2, 5):
  15. raise Exception(
  16. "Python 2.4 is not supported by this version. "
  17. "Please use Celery versions 2.1.x or earlier.")
  18. from .local import Proxy
  19. def Celery(*args, **kwargs):
  20. from .app import App
  21. return App(*args, **kwargs)
  22. def _get_current_app():
  23. from .app import current_app
  24. return current_app()
  25. current_app = Proxy(_get_current_app)