[rabbitmq-discuss] FW: Python client to RabbitMQ.....error?

Lynton Grice lynton.grice at netweaverguru.com
Fri Sep 28 19:52:04 BST 2007


Hi there,

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='/')

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]

Thanks for the help

Lynton






More information about the rabbitmq-discuss mailing list