Browse Source

Fixes typo in docs (ACCEPT_CONTENT must be list/tuple). Closes #1455

Ask Solem 11 years ago
parent
commit
c879462012
2 changed files with 3 additions and 3 deletions
  1. 1 1
      celery/app/defaults.py
  2. 2 2
      docs/getting-started/first-steps-with-celery.rst

+ 1 - 1
celery/app/defaults.py

@@ -90,7 +90,7 @@ NAMESPACES = {
         'WRITE_CONSISTENCY': Option(type='string'),
     },
     'CELERY': {
-        'ACCEPT_CONTENT': Option(None, type='any'),
+        'ACCEPT_CONTENT': Option(None, type='list'),
         'ACKS_LATE': Option(False, type='bool'),
         'ALWAYS_EAGER': Option(False, type='bool'),
         'ANNOTATIONS': Option(type='any'),

+ 2 - 2
docs/getting-started/first-steps-with-celery.rst

@@ -296,7 +296,7 @@ If you are configuring many settings at once you can use ``update``:
 
     app.conf.update(
         CELERY_TASK_SERIALIZER='json',
-        CELERY_ACCEPT_CONTENT='json',  # Ignore other content
+        CELERY_ACCEPT_CONTENT=['json'],  # Ignore other content
         CELERY_RESULT_SERIALIZER='json',
         CELERY_TIMEZONE='Europe/Oslo',
         CELERY_ENABLE_UTC=True,
@@ -332,7 +332,7 @@ current directory or on the Python path, it could look like this:
 
     CELERY_TASK_SERIALIZER = 'json'
     CELERY_RESULT_SERIALIZER = 'json'
-    CELERY_ACCEPT_CONTENT='json'
+    CELERY_ACCEPT_CONTENT=['json']
     CELERY_TIMEZONE = 'Europe/Oslo'
     CELERY_ENABLE_UTC = True