app.celery.MyCelery.config_from_object

MyCelery.config_from_object(obj, silent=False, force=False, namespace=None)

Read configuration from object.

Object is either an actual object or the name of a module to import.

Example

>>> celery.config_from_object('myapp.celeryconfig')
>>> from myapp import celeryconfig
>>> celery.config_from_object(celeryconfig)
Parameters
  • silent (bool) – If true then import errors will be ignored.

  • force (bool) – Force reading configuration immediately. By default the configuration will be read only when required.