title: Celery with Django - AttributeError: 'AsyncResult' object has no attribute 'replace'
body: <p>I wrote a celery task that sets some values in my database when I click on a button on my web page. Everything is fine. Now I want to write a more complex task (disambiguation_task) that returns a string to my Django view (1.6.5). The code is:</p>
  
  <pre><code>task_id = disambiguation_task.apply_async([json.dumps(json_request)])
  async_result = AsyncResult(id=task_id,app=disambiguation_task)
  </code></pre>
  
  <p>As soon as I try to get the result (async_result.get()), it generates an error:</p>
  
  <pre><code>AsyncResult' object has no attribute 'replace'
  </code></pre>
  
  <p>with the following traceback:</p>
  
  <pre><code>File "/home/patrick/django/entite-tracker-master/entitetracker/docentites/views.py" in get
    466.             result = async_result.get()
  File "/usr/local/lib/python2.7/dist-packages/celery/result.py" in get
    169.             no_ack=no_ack,
  File "/usr/local/lib/python2.7/dist-packages/celery/backends/amqp.py" in wait_for
    155.                                     on_interval=on_interval)
  File "/usr/local/lib/python2.7/dist-packages/celery/backends/amqp.py" in consume
    225.             binding = self._create_binding(task_id)
  File "/usr/local/lib/python2.7/dist-packages/celery/backends/amqp.py" in _create_binding
    99.         name = self.rkey(task_id)
  File "/usr/local/lib/python2.7/dist-packages/celery/backends/amqp.py" in rkey
    111.         return task_id.replace('-', '')
  
  Exception Type: AttributeError at /docentites/nodoc_desamb/news20150305NY501131/
  Exception Value: 'AsyncResult' object has no attribute 'replace' 
  </code></pre>
  
  <p>Same error if I try to print async_result.state.
  Can someone help me with this error?
  Regards,
  Patrick</p>