Can somebody give me an advice about what to learn?

Roy Smith roy at panix.com
Sun Sep 30 10:23:35 EDT 2012


In article <mailman.1672.1349011558.27098.python-list at python.org>,
 Chris Angelico <rosuav at gmail.com> wrote:

> there's no efficient and reliable way to change/reload code in a 
> running application (not often an issue).

What we do (largely cribbed from django's runserver) is start up a 
thread which once a second, looks at all the modules in sys.modules, 
checks to see if the modification time for their source files has 
changed, and if so, restarts the application.  This is hugely convenient 
when developing any kind of long-running application.  You don't need to 
keep restarting the application; just edit the source and changes take 
effect (almost) immediately.

Not sure if this is what you had in mind.



More information about the Python-list mailing list