[DB-SIG] shelve and hash function
Denis S. Otkidach
ods at strana.ru
Tue Jul 27 11:19:33 CEST 2004
On Sun, 25 Jul 2004, roy wrote:
r> I have a small app running under python 2.3, and I am trying
r> to port this to a
r> notebook running python 2.3.1.
r>
r> The trouble is that there are some data files using shelves
r> to store objects,
r> and there seems to be a compatibility problem.
r>
r> The error message I get is:-
r>
r> File "/usr/lib/python2.3/bsddb/__init__.py", line 192, in
r> hashopen
r> d.open(file, db.DB_HASH, flags, mode)
r> DBInvalidArgError: (22, 'Invalid argument -- data/foods:
r> unsupported hash
r> version: 8')
r>
r> Does this mean that an app using shelves is not really
r> portable?
Berkley DB files are not portable. You can use db_dump/db_load
utilities to convert database to/from portable plain text format.
r> How can I make the data files in a form that they can be
r> opened in any version
r> of Python?
Use slow but portable dumbdb instead of bsddb.
r> Does anyone have any experience with this kind of problem?
--
Denis S. Otkidach
http://www.python.ru/ [ru]
More information about the DB-SIG
mailing list