You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@qpid.apache.org by Omri Schwarz <om...@phasecap.com> on 2009/10/27 14:17:15 UTC
Python session object strangeness
Hi, all.
I have a TopicSubscriber Python class that I am writing to enable
my process to handle signals, as well as going quiescent when the
QPID broker goes down and resubscribing when it comes back up.
Right now I have this strangeness happening:
Traceback (most recent call last):
File "QpidTopicSubscriber.py", line 222, in <module>
main(sys.argv)
File "QpidTopicSubscriber.py", line 207, in main
msg = Q.queue.get(timeout=o.heartbeat)
File "/usr/lib/python2.5/Queue.py", line 174, in get
self.not_empty.wait(remaining)
File "/usr/lib/python2.5/threading.py", line 235, in wait
_sleep(delay)
File "QpidTopicSubscriber.py", line 203, in <lambda>
lambda foo,bar :sigint(foo,bar,Q))
File "QpidTopicSubscriber.py", line 132, in sigint
c.stop()
File "QpidTopicSubscriber.py", line 124, in stop
self.session.close()
File "/usr/lib/python2.5/site-packages/qpid/session.py", line 110, in
close
self.channel.session_detach(self.name)
AttributeError: 'NoneType' object has no attribute 'session_detach'
Note I have a signal handler that takes the signal details, adds in the
actual subscriber and then calls stop() on the Session object. At that
point I get this exception. From the code I see the .channel attribute
is set to None. What should be happening wqith it?
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org