title: How to configure CELERYBEAT_SCHEDULE in Django settings?
body: <p>I can get this to run as a standalone application, but I am having trouble getting it to work in Django.</p>
  
  <h2>Here is the stand alone code:</h2>
  
  <pre><code>from celery import Celery
  from celery.schedules import crontab
  
  
  app = Celery('tasks')
  app.conf.update(
      CELERY_TASK_SERIALIZER='json',
      CELERY_RESULT_SERIALIZER='json',
      CELERY_ACCEPT_CONTENT=['json'],
      CELERY_TIMEZONE='US/Central',
      CELERY_ENABLE_UTC=True,
      CELERYBEAT_SCHEDULE = {
      'test': {
          'task': 'tasks.test',
          'schedule': crontab(),
          },
      }
  )
  
  @app.task
  def test():
      with open('test.txt', 'a') as f:
          f.write('Hello, World!\n')`
  </code></pre>
  
  <p>It feeds the Rabbitmq server and writes to the file every minute. It works like a charm, but when I try to get it to work in a Django I get this error:</p>
  
  <blockquote>
    <blockquote>
      <p>Did you remember to import the module containing this task? Or maybe you are using relative imports? Please see ____ for
      more information.</p>
    </blockquote>
    
    <p>The full contents of the message body was: {'retries': 0, 'eta': None,
    'kwargs': {}, 'taskset': None, 'timelimit': [None, None], 'callbacks':
    None, 'task': 'proj.test', 'args': [], 'expires': None, 'id':
    '501ca998-b5eb-4ba4-98a8-afabda9e88dd', 'utc': True, 'errbacks': None,
    'chord': None} (246b) Traceback (most recent call last):   File
    "/home/user/CeleryDjango/venv/lib/python3.5/site-packages/celery/worker/consumer.py",
    line 456, in on_task_received
        strategies[name](message, body, KeyError: 'proj.test' [2016-06-16 01:16:00,051: INFO/Beat] Scheduler: Sending due task test (proj.test)
    [2016-06-16 01:16:00,055: ERROR/MainProcess] Received unregistered
    task of type 'proj.test'.</p>
  </blockquote>
  
  <h2>And this is my code in Django:</h2>
  
  <pre><code># CELERY STUFF
  CELERY_ACCEPT_CONTENT = ['application/json']
  CELERY_TASK_SERIALIZER = 'json'
  CELERY_RESULT_SERIALIZER = 'json'
  CELERY_TIMEZONE = 'US/Central'
  CELERYBEAT_SCHEDULE = {
      'test': {
          'task': 'proj.test',
          'schedule': crontab(),
      }
  }
  </code></pre>
  
  <hr>
  
  <p>celery.py</p>
  
  <pre><code>from __future__ import absolute_import
  
  import os
  from celery import Celery
  os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'proj.settings')
  from django.conf import settings  # noqa
  
  app = Celery('proj')
  
  app.config_from_object('django.conf:settings')
  app.autodiscover_tasks(lambda: settings.INSTALLED_APPS)
  
  
  @app.task(bind=True)
  def debug_task(self):
      print('Request: {0!r}'.format(self.request))
  </code></pre>
  
  <hr>
  
  <p>task.py</p>
  
  <pre><code>from __future__ import absolute_import
  from celery import shared_task
  
  
  @shared_task
  def test():
      with open('test.txt', 'w') as f:
          print('Hello, World', file=f)
  </code></pre>
  
  <hr>
  
  <p>init.py</p>
  
  <pre><code>from __future__ import absolute_import
  
  from .celery import app as celery_app 
  </code></pre>
  
  <p>Any thoughts on this are most appreciated. Thanks.</p>