Problems with ZODB's persistence module

0 views
Skip to first unread message

sk...@pobox.com

unread,
Dec 18, 2009, 7:30:47 PM12/18/09
to unladen...@googlegroups.com

So I've got my SpamBayes test integrated into the u-s perf.py framework
and now find I can't run it with Unladen Swallow. Works fine with
Python 2.6:

% python2.6 bm_spambayes.py
0.967751979828

but I get a C API version warning and a bus error with u-s:

% ~/src/unladen-swallow/python.exe bm_spambayes.py
/Users/skip/local/lib/python2.6/site-packages/persistent/__init__.py:19: RuntimeWarning: Python C API version mismatch for module cPersistence: This Python has API version 1014, module cPersistence has version 1013.
from cPersistence import Persistent, GHOST, UPTODATE, CHANGED, STICKY
Bus error

Shouldn't Unladen Swallow have the same C API version as Python 2.6?

Skip

James Abbatiello

unread,
Dec 18, 2009, 9:12:38 PM12/18/09
to sk...@pobox.com, unladen...@googlegroups.com
On Fri, Dec 18, 2009 at 7:30 PM, <sk...@pobox.com> wrote:
> Shouldn't Unladen Swallow have the same C API version as Python 2.6?

It was changed in
http://code.google.com/p/unladen-swallow/source/detail?r=890
Certain flags have changed and the size of some structs has been
increased. It should be source compatible but not binary compatible
with existing Python C extension modules.

Are you using the version from the ZODB in the tests repository? I've
found that `setup.py install` isn't smart enough to figure out that
things need to be recompiled. I had to delete all the compiled copies
and the build directory and reinstall to get it to build again and
pick up the changes.

--
James Abbatiello

sk...@pobox.com

unread,
Dec 18, 2009, 11:34:54 PM12/18/09
to James Abbatiello, unladen...@googlegroups.com

>> Shouldn't Unladen Swallow have the same C API version as Python 2.6?

James> It was changed in
James> http://code.google.com/p/unladen-swallow/source/detail?r=890

James> Certain flags have changed and the size of some structs has been
James> increased. It should be source compatible but not binary
James> compatible with existing Python C extension modules.

OK, so that means I should probably "make altinstall". Unfortunately, that
means I won't be able to install u-s the way I would install Python 2.6
since it appears with the same --prefix setting they will land in the same
directories. Am I missing something? How do people have these two versions
installed side-by-side? Just suffer with a different --prefix?

James> Are you using the version from the ZODB in the tests repository?

No, I have a ZODB 3.6.0 source tree I've been installing from. I think once
I have u-s installed suitably I'll be ok.

Skip

James Abbatiello

unread,
Dec 18, 2009, 11:43:49 PM12/18/09
to sk...@pobox.com, unladen...@googlegroups.com
On Fri, Dec 18, 2009 at 11:34 PM, <sk...@pobox.com> wrote:
> OK, so that means I should probably "make altinstall".  Unfortunately, that
> means I won't be able to install u-s the way I would install Python 2.6
> since it appears with the same --prefix setting they will land in the same
> directories.  Am I missing something?  How do people have these two versions
> installed side-by-side?  Just suffer with a different --prefix?

See this thread for some discussion:
http://groups.google.com/group/unladen-swallow/browse_frm/thread/93350a6d7919201c
I'm not sure what people are actually doing.

--
James Abbatiello

sk...@pobox.com

unread,
Dec 19, 2009, 12:01:21 AM12/19/09
to James Abbatiello, unladen...@googlegroups.com

James> See this thread for some discussion:
James> http://groups.google.com/group/unladen-swallow/browse_frm/thread/93350a6d7919201c
James> I'm not sure what people are actually doing.

Thanks. For the time being I will just change the prefix and create a
symlink in my local bin directory named "unladen". If/when something more
formal comes along I can adjust easily enough.

Skip

Reply all
Reply to author
Forward
0 new messages