SimpleXMLRPCServer Releasing Ports
Robert
k.robert at gmx.de
Wed Oct 9 13:24:20 EDT 2002
I did this on a windows box.
even with REUSE = no I could restart my SimpleXMLRPCServer script immediatly
but first my script stored the server object globally like
"sv=SimpleXMLRPCServer.SimpleXMLRPCServer((ip,80))".
Of course in such case you should simply delete the last instance of the
server first: 'del sv' or sv.server_close() :-)
If you really really want REUSE you could change policy simply by
SimpleXMLRPCServer.SimpleXMLRPCServer.allow_reuse_address=1 before
instantiating. (or subclass the simple server)
-Robert
"John Abel" <john.abel at pa.press.net> schrieb im Newsbeitrag
news:mailman.1034078772.26126.python-list at python.org...
> Hi,
>
> I have a script running, using SimpleXMLRPCServer, which works OK.
> Except, when I stop, and restart the script, I receive the error,
> "Address already in use". Is there something I can do, like a
> destructor, to tidy up, so that the script can be restarted?
>
> Thanks
>
> John
>
>
>
More information about the Python-list
mailing list