[mod_python] Changes to modules seem to get cached

Roy Smith roy.smith at micromuse.com
Tue Apr 9 22:14:29 EST 2002


I'm running:

Apache 1.3.22
Python 2.1.2
mod_python 2.7.6
Red Hat 6.2
Netscape 4.72

I'm just starting to play around with mod_python.  So far it seems pretty 
neat, but I don't quite understand how mod_python notices when a module 
gets updated, and what it does when it notices.

Most of the time, if I edit my python file and reload my browser window, I 
get the results of the new module.  Sometimes, however, it seems like I've 
got to reload twice to see the effect of the change.  This seems to be more 
likely to happen if the last version of the module generated an error. 
Even weirder, I can get into states where if I keep hitting reload, I'll 
cycle through a number of different earlier versions of the page.

I've got several httpd's running, and I'm guessing each time I do a reload 
it gets served by a different process, and apparantly each process has a 
different version of the module cached.  What I don't understand is why 
each process doesn't notice that the disk file has changed and re-import 
the module.  Or maybe my understanding of what's going on is totally off 
the wall?



--
Roy Smith
Staff Engineer
Visionary Model Development
roy.smith at micromuse.com
+1 914 747 7612




More information about the Mod_python mailing list