473,396 Members | 1,929 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

shelve module on a gentoo/amd64 machine

I've run into a problem on this platform (amd64) with code that works
elsewhere, on x86, sparc, and ppc platforms. The shelve module is throwing
an error raised from the anydbm call inside it:

Python 2.3.3 (#1, Feb 17 2004, 22:00:49)
[GCC 3.3.2 20040119 (Gentoo Linux 3.3.2-r7, propolice-3.3-7)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
import shelve
x = shelve.open('tsetse.fly') Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/lib/python2.3/shelve.py", line 231, in open
return DbfilenameShelf(filename, flag, protocol, writeback, binary)
File "/usr/lib/python2.3/shelve.py", line 212, in __init__
Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback,
binary)
File "/usr/lib/python2.3/anydbm.py", line 83, in open
return mod.open(file, flag, mode)
File "/usr/lib/python2.3/dbhash.py", line 16, in open
return bsddb.hashopen(file, flag, mode)
File "/usr/lib/python2.3/bsddb/__init__.py", line 192, in hashopen
d.open(file, db.DB_HASH, flags, mode)
bsddb._db.DBInvalidArgError: (22, 'Invalid argument -- DB_ENV->dbremove:
method not permitted before open')

raw calls to anydbm to open a db fail similarly:
x = anydbm.open('tsts', 'c')

Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/lib/python2.3/anydbm.py", line 83, in open
return mod.open(file, flag, mode)
File "/usr/lib/python2.3/dbhash.py", line 16, in open
return bsddb.hashopen(file, flag, mode)
File "/usr/lib/python2.3/bsddb/__init__.py", line 192, in hashopen
d.open(file, db.DB_HASH, flags, mode)
bsddb._db.DBInvalidArgError: (22, 'Invalid argument -- DB_ENV->dbremove:
method not permitted before open')

.... I'd love to know what's going on here. =) any clues deeply appreciated.
let me know if I can provide any more information.

-B
Jul 18 '05 #1
0 1097

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Rami A. Kishek | last post by:
Hi - this mysterious behavior with shelve is just about to kill me. I hope someone here can shed some light. First of all, I have this piece of code which uses shelve to save instances of some...
0
by: PiedmontBiz | last post by:
I am finishing up a simple survey for a web site. I am creating a server-side data base using the shelve module. I am a relative python newcomer. I began with anydbm, but found that shelve uses...
2
by: Michael P. Soulier | last post by:
I'm trying to add objects to a shelve db object via hash assignment, but I'm getting an odd exception. Traceback (most recent call last): File "RemGui.py", line 117, in onMonitorButton...
0
by: Bill | last post by:
I am trying to deploy a backend vb.net application on a production server. It works like a champ in the test env. But falls over very fast after I deploy it. It issues a message 'application has...
1
by: mathieu.malaterre | last post by:
Hello, I am trying to build an executable that link against python libraries. If I only link to python lib I get thoses errors(*). This machine is a gentoo AMD64. I installed python by doing...
4
by: softwindow | last post by:
according to the book instruduction , i use shelve Module to write record to file. i only write ten records like this: name sex age jim male 22 tom ...
6
by: John Pye | last post by:
Hi all I have a tricky situation that's preventing my Python/SWIG/C application from running on the Debian Etch AMD64 platform. It seems that the 'dl' module is not available on that platform....
0
by: Douglas Applegate | last post by:
Hi- I am having a problem with shelve. The problem I think is really with gdbm. I'll write out a file using shelve/gdbm on an amd64 machine and then I'll try to read it in on a i386 machine. The...
0
by: Gabriel Genellina | last post by:
En Mon, 28 Apr 2008 02:08:31 -0300, tarun <tarundevnani@gmail.comescribió: By default, each time you do d you get a *different* object. A shelve isn't very smart: it stores a string...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.