Upgrading an instance to a subclass

Antoon Pardon apardon at forel.vub.ac.be
Wed Oct 8 13:54:03 CEST 2008

I have a subclass of socket.

class Mysocket (socket):

But when I use the python library it will of course
just return an instance of socket, like the SocketServer

So now I was wondering if it is somehow possible to
turn this instance into a Mysocket instance, either
by somehow changing the original instance or producing
a new instance that represents the same connection.

Antoon Pardon

More information about the Python-list mailing list