[mod_python] Apache reload problem

harm-modpython at tty.nl harm-modpython at tty.nl
Tue Oct 2 23:40:00 EST 2001


On Tue, Oct 02, 2001 at 09:19:46PM +0200, Ole Hansen wrote:
> Hi again,
> 
> Am I the only one having this kind of problem?

Actually, no!

Had the same problem a few weeks, with a new python, apache and mod_python.
Making a script.pyc solved it, haven`t look into it yet.



Harmen


> 
> Br,
> Ole Hansen
> 
> 
> On Sunday 30 September 2001 23:42, you wrote:
> > Hi,
> >
> > I have just joined this list, so this subject might have been covered
> > before. However, the problem is that whenever I change something in my
> > '.py'-file apache fails to reload the page. From error_log it seems like
> > apache searches for a file with the extension '.p' instead of '.py' - so I
> > modified mod_python/apache.py a little.
> > I replaced (filepath[:-1]) with (filepath[:]) in the following piece of
> > code. line 356 and 359 in apache.py
> >
> >
> > <snip>
> >             # check also .py and take the newest
> >             if os.path.exists(filepath[:]) :
> >
> >                 # get the time of the .py file
> >                 mod = os.stat(filepath[:])
> >                 mtime = max(mtime, mod[stat.ST_MTIME])
> > <snip>
> >
> > Apache hasn't complained ever since - but this is perhaps not a very good
> > solution. Does anybody have another and maby better solution?
> > I'm using apache 1.3.19, mod_python 2.7.5, and Python 2.1.1.
> > The file permissions for my '.py'-file is like 'chmod ugo+rwx', so I don't
> > think this the problem.
> >
> > I'm  a newbie to mod_python/Python/Apache so I might have overlooked
> > something.
> >

-- 
                                                        The Moon is Full



More information about the Mod_python mailing list