You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Python doesn't detect Berkeley DB 4.8. After updating setup.py, _bsddb
module fails to build due to some changes in Berkeley DB.
I'm attaching patch which seems to fix these problems.
Changes in setup.py were made by me.
Changes in Modules/_bsddb.c were copied from bsddb3-4.8.0 [1].
with this patch the following test cases fail. the tests need backports as well. with this patch there's still one test failure, which I do see with db4.7 as well.
will wait for test results on different platforms and then submit to the trunk. the setup.py change should go to the py3k branch as well.
Traceback (most recent call last):
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_basics.py", line 1038, in test02_DBEnv_deallocself.assertRaises(db.DBInvalidArgError, db.DBEnv, ~db.DB_RPCCLIENT)
AttributeError: 'module' object has no attribute 'DB_RPCCLIENT'
Traceback (most recent call last):
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_distributed_transactions.py", line 53, in setUpreturnself._create_env(must_open_db=True)
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_distributed_transactions.py", line 38, in _create_envself.db.set_re_len(db.DB_XIDDATASIZE)
AttributeError: 'module' object has no attribute 'DB_XIDDATASIZE'
Traceback (most recent call last):
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_distributed_transactions.py", line 53, in setUpreturnself._create_env(must_open_db=True)
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_distributed_transactions.py", line 38, in _create_envself.db.set_re_len(db.DB_XIDDATASIZE)
AttributeError: 'module' object has no attribute 'DB_XIDDATASIZE'
Traceback (most recent call last):
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_distributed_transactions.py", line 53, in setUpreturnself._create_env(must_open_db=True)
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_distributed_transactions.py", line 38, in _create_envself.db.set_re_len(db.DB_XIDDATASIZE)
AttributeError: 'module' object has no attribute 'DB_XIDDATASIZE'
Traceback (most recent call last):
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_distributed_transactions.py", line 53, in setUpreturnself._create_env(must_open_db=True)
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_distributed_transactions.py", line 38, in _create_envself.db.set_re_len(db.DB_XIDDATASIZE)
AttributeError: 'module' object has no attribute 'DB_XIDDATASIZE'
test_bsddb3
Berkeley DB 4.8.24: (August 14, 2009)
Test path prefix: /tmp/z-test_bsddb3-25705
Exception in thread reader 0:
Traceback (most recent call last):
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/threading.py", line 532, in __bootstrap_innerself.run()
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/threading.py", line 484, in runself.__target(*self.__args, **self.__kwargs)
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/test/test_thread.py", line 306, in readerThread
rec = dbutils.DeadlockWrap(c.next, max_retries=10)
File "/home/packages/python/2.6/python2.6-2.6.5~rc2/Lib/bsddb/dbutils.py", line 68, in DeadlockWrapreturn function(*_args, **_kwargs)
DBLockDeadlockError: (-30994, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock')
Activity
Arfrever commentedon Sep 19, 2009
Python doesn't detect Berkeley DB 4.8. After updating setup.py, _bsddb
module fails to build due to some changes in Berkeley DB.
I'm attaching patch which seems to fix these problems.
Changes in setup.py were made by me.
Changes in Modules/_bsddb.c were copied from bsddb3-4.8.0 [1].
[1] http://www.jcea.es/programacion/pybsddb.htm
doko42 commentedon Mar 14, 2010
with this patch the following test cases fail. the tests need backports as well. with this patch there's still one test failure, which I do see with db4.7 as well.
will wait for test results on different platforms and then submit to the trunk. the setup.py change should go to the py3k branch as well.
======================================================================
ERROR: test02_DBEnv_dealloc (bsddb.test.test_basics.CrashAndBurn)
----------------------------------------------------------------------
======================================================================
ERROR: test01_distributed_transactions (bsddb.test.test_distributed_transactions.DBTxn_distributed)
----------------------------------------------------------------------
======================================================================
ERROR: test01_distributed_transactions (bsddb.test.test_distributed_transactions.DBTxn_distributedSYNC)
----------------------------------------------------------------------
======================================================================
ERROR: test01_distributed_transactions (bsddb.test.test_distributed_transactions.DBTxn_distributed_must_open_db)
----------------------------------------------------------------------
======================================================================
ERROR: test01_distributed_transactions (bsddb.test.test_distributed_transactions.DBTxn_distributedSYNC_must_open_db)
----------------------------------------------------------------------
doko42 commentedon Mar 14, 2010
the remaining test failure is
doko42 commentedon Mar 15, 2010
checked in after testing on {arm,i486,x86_64,powerpc,sparc,ia64}-linux with no test failures.
fixed in r78974 on the trunk
fixed in r78975 on the py3k branch
jcea commentedon Mar 16, 2010
I am about to integrate pybsddb 4.8.4, that compiles against BDB 4.8.
Oracle is going to publish a new Berkeley DB lib in a month or less. I have the pybsddb release ready, too.
jcea commentedon Mar 16, 2010
Doko, bsddb3 is suppose to be "out" of py3k.
doko42 commentedon Mar 16, 2010
jcea: yes, but we want _dbm be able to build with 4.8.x as well.