我正在使用SQS
celery worker -A project.celery --loglevel=info
使用相同的sqs连接字符串信息,我可以连接到sqs队列,并修改/写入消息。但芹菜工人不会开始。它给了我错误:
[2017-04-27 00:11:34,592: CRITICAL/MainProcess] Unrecoverable error: TypeError('invalid arguments to setopt',)
Traceback (most recent call last):
File "/usr/local/lib/python2.7/site-packages/celery/worker/worker.py", line 203, in start
self.blueprint.start(self)
File "/usr/local/lib/python2.7/site-packages/celery/bootsteps.py", line 119, in start
step.start(parent)
File "/usr/local/lib/python2.7/site-packages/celery/bootsteps.py", line 370, in start
return self.obj.start()
File "/usr/local/lib/python2.7/site-packages/celery/worker/consumer/consumer.py", line 318, in start
blueprint.start(self)
File "/usr/local/lib/python2.7/site-packages/celery/bootsteps.py", line 119, in start
step.start(parent)
File "/usr/local/lib/python2.7/site-packages/celery/worker/consumer/consumer.py", line 594, in start
c.loop(*c.loop_args())
File "/usr/local/lib/python2.7/site-packages/celery/worker/loops.py", line 88, in asynloop
next(loop)
File "/usr/local/lib/python2.7/site-packages/kombu/async/hub.py", line 282, in create_loop
item()
File "/usr/local/lib/python2.7/site-packages/vine/promises.py", line 139, in __call__
return self.throw()
File "/usr/local/lib/python2.7/site-packages/vine/promises.py", line 136, in __call__
retval = fun(*final_args, **final_kwargs)
File "/usr/local/lib/python2.7/site-packages/kombu/transport/SQS.py", line 290, in _schedule_queue
queue, callback=promise(self._loop1, (queue,)),
File "/usr/local/lib/python2.7/site-packages/kombu/transport/SQS.py", line 306, in _get_bulk_async
return self._get_async(queue, maxcount, callback=callback)
File "/usr/local/lib/python2.7/site-packages/kombu/transport/SQS.py", line 316, in _get_async
callback=transform(self._on_messages_ready, callback, q, queue),
File "/usr/local/lib/python2.7/site-packages/kombu/transport/SQS.py", line 336, in _get_from_sqs
callback=callback,
File "/usr/local/lib/python2.7/site-packages/kombu/async/aws/sqs/connection.py", line 82, in receive_message
queue.id, callback=callback,
File "/usr/local/lib/python2.7/site-packages/kombu/async/aws/connection.py", line 239, in get_list
self._on_list_ready, callback, parent or self, markers,
File "/usr/local/lib/python2.7/site-packages/kombu/async/aws/connection.py", line 232, in make_request
return self._mexe(request, callback=callback)
File "/usr/local/lib/python2.7/site-packages/kombu/async/aws/connection.py", line 198, in _mexe
conn.getresponse(callback=callback)
File "/usr/local/lib/python2.7/site-packages/kombu/async/aws/connection.py", line 129, in getresponse
return self.http_client.add_request(request)
File "/usr/local/lib/python2.7/site-packages/kombu/async/http/curl.py", line 74, in add_request
self._process_queue()
File "/usr/local/lib/python2.7/site-packages/kombu/async/http/curl.py", line 152, in _process_queue
self._setup_request(curl, request, buf, headers)
File "/usr/local/lib/python2.7/site-packages/kombu/async/http/curl.py", line 186, in _setup_request
setopt(_pycurl.URL, bytes_to_str(request.url))
TypeError: invalid arguments to setopt
有人可以帮我弄清楚配置/启动错误是什么吗?
答案 0 :(得分:0)
好的,所以我最终使用类似于另一个答案的URL更改。来自:
的经纪人网址my_app
|
|- main.py
|
|- kivy/uix/recycleview (multiple folders, not ONE)
到
"sqs://id:key@"
让服务运行,但实际上不允许我连接到sqs
我实际上最终做的是放弃sqs,并在带有弹性的redis上运行所有东西。这很容易