[rabbitmq-discuss] FW: Python client to RabbitMQ.....error?
Matthias Radestock
matthias at lshift.net
Fri Sep 28 20:06:34 BST 2007
Lynton,
Lynton Grice wrote:
> OK.....it works now....well almost......the problem was the VHOST....for
> some reason the VHOST in the log file was 127.0.0.1....see below
>
> =INFO REPORT==== 28-Sep-2007::16:04:07 === VHost access refused: no
>> mapping for User <<"guest">>, VHost <<"127.0.0.1">>
>
> So I changed the code to:
>
> client = Client("127.0.0.1", 5672,
> spec=qpid.spec.load('amqp0-8.xml'),vhost='/')
IMHO it is a bit strange for the vhost to default to the IP. You may
want to raise that with the qpid folks.
> And now it works.....BUT now I have another problem.....it dies when trying
> to receive the message it have just put onto the queue....
>
> msg = q.get(timeout=1)
>
> That throws the following exception:
>
> KeyError: __eq__
>
> Traceback (innermost last):
>
> File "D:\tmp\Rabbit\rabbit.py", line 1, in ?
> import qpid
> File "D:\tmp\Rabbit\rabbit.py", line 22, in ?
> msg = q.get(timeout=1)
> File "D:\Python24\Lib\site-packages\qpid\queue.py", line 39, in get
> if result == Queue.END:
> File "D:\Python24\Lib\site-packages\qpid\message.py", line 70, in
> __getattr__
> env, key = self._slot(attr)
> File "D:\Python24\Lib\site-packages\qpid\message.py", line 63, in _slot
> field = self.method.fields.bypyname[attr]
Is there anything unusual in the RabbitMQ logs? Check the LOG_BASE
directory - C:\Documents and Settings\User\rabbitmq\log if you are
using the default settings.
Also, which version of the amqp0-8.xml spec file are you using? The one
that comes with the qpid distribution is not the official version.
Replace it with the official version from
https://jira.amqp.org/confluence/download/attachments/720900/amqp0-8.xml.
I don't think that's the problem in this particular case though.
Matthias.
More information about the rabbitmq-discuss
mailing list