[Twisted-Python] WSGI Question

Phil Christensen phil at bubblehouse.org
Wed Jan 20 13:51:49 EST 2010


On Jan 20, 2010, at 10:40 AM, Landreville wrote:
> On Wed, Jan 20, 2010 at 9:58 AM, adamjamesdrew same <theiklabs at gmail.com> wrote:
>> I deploy code. Then I modify the code on my file system. The code does not
>> automatically change on the server. It does this on the django dev server.
>> How can I make this happen?
> The twisted modules are only loaded once because it asynchronous, so
> the twisted server is persistent in memory. You only load your twisted
> app once, whereas in django the modules are reloaded on every page
> refresh on the dev server.

No, this is not the case.

Twisted's function in this regard is because there's no autoreload functionality, not because of anything to do with its asynchronous development style.

The Django dev server *does not* reload on every page request, it only does so when the files in question have been modified. The Django dev server is also persistent in memory, and uses forking to isolate reloadable code into its own process. When the code fails, or needs to be reloaded, the child is killed and respawned.

-phil


More information about the Twisted-Python mailing list