Django + Celery: 'str' object has no attribute 'publish_task'
<p>I'm using Celery to send emails asynchronously with Django. When I'm trying to use a task, I get an error stating <code>'str' object has no attribute 'publish_task'</code>. From the logs, it seems like the error lies in Celery's code, but my code could also be the source. Here are my logs:</p>

<pre><code>Environment:

Request Method: GET
Request URL: http://127.0.0.1:8000/reminder/

Django Version: 1.8.5
Python Version: 3.4.3
Installed Applications:
('django.contrib.admin',
 'django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.messages',
 'django.contrib.staticfiles',
 'django.contrib.sites',
 'crispy_forms',
 'bootstrap3_datetime',
 'haystack',
 'registration',
 'tinymce',
 'djcelery',
 'djcelery_email',
 'RemindApp',
 'home',
 'BookRoom',
 'GameDev')
Installed Middleware:
('django.contrib.sessions.middleware.SessionMiddleware',
 'django.middleware.common.CommonMiddleware',
 'django.middleware.csrf.CsrfViewMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
 'django.contrib.messages.middleware.MessageMiddleware',
 'django.middleware.clickjacking.XFrameOptionsMiddleware',
 'django.middleware.security.SecurityMiddleware',
 'django.middleware.locale.LocaleMiddleware')


Traceback:
File "C:\Users\Tony\Desktop_Files\Envs\ReminderVenv\lib\site-packages\django\core\handlers\base.py" in get_response
  132.                     response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "C:\Users\Tony\Desktop_Files\Envs\ReminderVenv\lib\site-packages\django\contrib\auth\decorators.py" in _wrapped_view
  22.                 return view_func(request, *args, **kwargs)
File "C:\Users\Tony\Desktop_Files\Programming\Django\Reminder\RemindApp\views.py" in index
  49.                                     request.user.email)
File "C:\Users\Tony\Desktop_Files\Envs\ReminderVenv\lib\site-packages\celery\app\task.py" in apply_async
  565.             **dict(self._get_exec_options(), **options)
File "C:\Users\Tony\Desktop_Files\Envs\ReminderVenv\lib\site-packages\celery\app\base.py" in send_task
  350.             task_id = P.publish_task(

Exception Type: AttributeError at /reminder/
Exception Value: 'str' object has no attribute 'publish_task'
</code></pre>

<p>In addition, here is my task:</p>

<pre><code>@celery.task
def Mailer_Send(reminder, reminder_title, user, email):
    mail = Mailer()
    mail.send_messages(
        subject = "Time's up! {} is due".format(reminder_title),
        template = 'reminder/email.html',
        context = {'user': user, 'post': reminder},
        to_emails = [email]
    )
    logger.info('Sending email for reminder: {}'.format(reminder_title))
</code></pre>

<p>And here is where I'm trying to use the task:</p>

<pre><code>Mailer_Send.apply_async(reminder_note,
                        reminder_note.title,
                        request.user,
                        request.user.email)
</code></pre>