re-importing modules

Paul Rubin http
Tue May 1 01:51:23 EDT 2007


Graham Dumpleton <Graham.Dumpleton at gmail.com> writes:
> That it doesn't reload a parent when a child changes may be fine in an
> interactive debugger, but can cause problems if not done where
> automatic reloading is being done in a long running web application
> where you want to avoid server restarts. 

Oh that sounds horrid.  If you really have to do something like that,
it's time to consider adding serious hot-patching capability as I
believe Erlang has done.  Better is to start a new server process and
transfer the live session data and active connections to it through
IPC mechanisms.  I've had an open RFE for many years (#814689) about
ancillary messages on AF_UNIX sockets, which let you pass file
descriptors (such as those attached to open TCP connections) between
processes.  It actually came up in conversation with someone about
something I'm currently working on, so maybe I'll have reason to try
coding it sometime soon (that's not at all definite though).



More information about the Python-list mailing list