[mod_python] Session Pickling Error

Terence MacDonald terry.macdonald at dsl.pipex.com
Mon Oct 3 20:02:27 EDT 2005


Apologies if this is not the right place to post this but I am reaching
my wits end and any help on the matter would be very much appreciated.

I have a web application written/using:

python 2.3.4
mod_python 3.1.4
apache 2.0.49  (mpm prefork mode)
PyPgSQL 2.4

I use mod_python sessions to save data between client web page
submissions.

After moving the apparently working application onto a more powerful
server I have begun to get the following intermittent error when saving
the session data.
 
PicklingError: Can't pickle <function _B at 0x2a9ec93758>: it's not the
same object as pyPgSQL.libpq._B

Additional (helpful?) info:
_B is, I believe, a helper function for the PgBoolean type defined by
PyPgSQL.
The session data can have data containing a PgBoolean instance
represented as <PgBoolean instance at 0x2aa0313680: Value: True> in a
dump of the session data.
Most of the time it works!
I use mod_python's import_module().

To be honest I don't fully understand the problem so I can't be sure
if/when I fix it because of the irregular occurrences of the error
(memory issue?)

In need of a little guidance, thanks



More information about the Mod_python mailing list