[mod_python] import site errors, and constant modules (Re)loading

Joshua Schmidlkofer menion at asylumwear.com
Tue Dec 9 11:49:56 EST 2003


I have poked through the list archives, and I still am.  I have Redhat
with mod_python-3.0.1 - the rpm packaged release.  In any case, whenever
I call my script it is re-instantiating the objects..

my script is like:

<snip>
class foo:
    def __init__(self):
        self.dbconn = psycopg.connect(.....)
        pass
    def handler(self, req):
        ....
        return content

__classholder__ = foo()
handler = foo.handler
</snip>

Did I fail to grok the greater meaning?  Am I committing a rookie
error?   I have turned on debug mode, and everytime I call the script I
get : 

[Tue Dec 09 11:18:25 2003] [notice] mod_python: (Re)importing module
'update' with path set to '['/var/www/html/proxy']'
'import site' failed; use -v for traceback
(this repeats about 20 times)


Anyway, thanks,
  joshua (going back to google)

-- 
I refuse to believe that the really hot, Debian-using,
password-sniffing, root-exploiting geek girl is a myth. -- g1zmo



More information about the Mod_python mailing list