代码就是这里了:https://github.com/mher/tornado-celery/报错:Traceback(mostrecentcalllast):File"/usr/local/lib/python2.7/dist-packages/tornado-4.0.2-py2.7-linux-x86_64.egg/tornado/web.py",line1288,in_stack_context_handle_exceptionraise_exc_info((type,value,traceback))File"/usr/local/lib/python2.7/dist-packages/tornado-4.0.2-py2.7-linux-x86_64.egg/tornado/web.py",line1475,inwrapperresult=method(self,*args,**kwargs)File"examples/tornado_async.py",line14,ingettasks.sleep.apply_async(args=[3],callback=self.on_result)File"/usr/local/lib/python2.7/dist-packages/celery-3.1.17-py2.7.egg/celery/app/task.py",line555,inapply_async**dict(self._get_exec_options(),**options)File"/usr/local/lib/python2.7/dist-packages/celery-3.1.17-py2.7.egg/celery/app/base.py",line353,insend_taskreply_to=reply_toorself.oid,**optionsFile"/usr/local/lib/python2.7/dist-packages/celery-3.1.17-py2.7.egg/celery/app/amqp.py",line305,inpublish_task**kwargsFile"/usr/local/lib/python2.7/dist-packages/kombu-3.0.24-py2.7.egg/kombu/messaging.py",line168,inpublishrouting_key,mandatory,immediate,exchange,declare)File"/usr/local/lib/python2.7/dist-packages/kombu-3.0.24-py2.7.egg/kombu/connection.py",line436,in_ensuredreturnfun(*args,**kwargs)File"/usr/local/lib/python2.7/dist-packages/kombu-3.0.24-py2.7.egg/kombu/messaging.py",line184,in_publishmandatory=mandatory,immediate=immediate,File"/usr/local/lib/python2.7/dist-packages/kombu-3.0.24-py2.7.egg/kombu/transport/virtual/__init__.py",line521,inbasic_publishmessage,exchange,routing_key,**kwargsFile"/usr/local/lib/python2.7/dist-packages/kombu-3.0.24-py2.7.egg/kombu/transport/virtual/exchange.py",line61,indeliver_put(queue,message,**kwargs)File"/usr/local/lib/python2.7/dist-packages/kombu-3.0.24-py2.7.egg/kombu/transport/redis.py",line673,in_putclient.lpush(self._q_for_pri(queue,pri),dumps(message))File"/usr/local/lib/python2.7/dist-packages/anyjson-0.3.3-py2.7.egg/anyjson/__init__.py",line141,indumpsreturnimplementation.dumps(value)File"/usr/local/lib/python2.7/dist-packages/anyjson-0.3.3-py2.7.egg/anyjson/__init__.py",line87,indumpsreturnself._encode(data)File"/usr/lib/python2.7/json/__init__.py",line231,indumpsreturn_default_encoder.encode(obj)File"/usr/lib/python2.7/json/encoder.py",line201,inencodechunks=self.iterencode(o,_one_shot=True)File"/usr/lib/python2.7/json/encoder.py",line264,initerencodereturn_iterencode(o,0)File"/usr/lib/python2.7/json/encoder.py",line178,indefaultraiseTypeError(repr(o)+"isnotJSONserializable")TypeError:isnotJSONserializable
摇曳的蔷薇
相关分类