[Twisted-Python] Sending a "good-bye message" before closing a connection

Itamar Turner-Trauring itamar at itamarst.org
Fri Nov 18 08:31:18 EST 2011

On Fri, 2011-11-18 at 12:23 +0100, Albert Brandl wrote:

> But sometimes, the clients have to go offline. In this case, I'd like 
> them to send a message to the server that they will be gone for a
> while.
> When a client goes offline, the twistd daemon for handling the
> heartbeats
> is shut down.

Presumably there is a method somewhere that decides to close the
connection down:

   def timeToShutdown(self):

So instead do:

   def timeToShutdown(self):

More information about the Twisted-Python mailing list