python manage.py runserver
--
Joel Goldstick
--
Joel Goldstick
On Mon, Apr 23, 20ogr12 at 9:16 AM, Joel Goldstick
I suspect that you can do this (assuming that you don't want to run the
*nix "touch" command as a sub process, or don't have it because you
are on an OS that doesn't have it) by opening the file for writing, not
writing to it, and closing it again. But note that I haven't tested this on
any platform, let alone yours.
The development server is actually two processes: the one you start
with manage, and the one actually running Django, which is started by
the first "driver" process. The driver process then spends its time
watching for files to change, and when it sees one do so, it restarts
the server process. However you can manage to implement touch on
your platform.
Note that this is specific to the development server. But note that mod_wsgi
has a similar watch upon just the .wsgi file (which doesn't have to be
named with .wsgi, it's just the one that the WSGIScripAlias points to).
Change your code so you don't have to. Relying on a restart for that
is the wrong approach.