This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: bsddb.btopen . del of record doesn't update index
Type: Stage:
Components: Library (Lib) Versions:
process
Status: closed Resolution: duplicate
Dependencies: Superseder:
Assigned To: Nosy List: nnorwitz, quixo
Priority: normal Keywords:

Created on 2007-05-27 05:15 by quixo, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
testbtopen.py quixo, 2007-05-27 05:15
Messages (2)
msg32137 - (view) Author: Charles Hixson (quixo) Date: 2007-05-27 05:15
A ram -resident database is creaed with btopen

10 records are added, keyed by sequence, value is sequence + 1 (both converted to strings).

I check to ensure that all of the records have been added.

I delete the first record, check the keys again, and it still works.

I delete the first record, check the keys again, and it fails, thusly:

python testbtopen.py
['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
0
1
2
3
4
5
6
7
8
9
0 1
['1', '2', '3', '4', '5', '6', '7', '8', '9']
1
2
3
4
5
6
7
8
9
Traceback (most recent call last):
  File "testbtopen.py", line 13, in ?
    i   =       db.first()[0]
  File "/usr/lib/python2.4/site-packages/PIL/__init__.py", line 269, in first

  File "/usr/lib/python2.4/site-packages/PIL/__init__.py", line 183, in _checkCursor

_bsddb.DBNotFoundError: (-30989, 'DB_NOTFOUND: No matching key/data pair found')
charles@mandala1:~/projects/Python/bsddb$ python testbtopen.py
['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
['0', '1', '2', '3', '4', '5', '6', '7', '8', '9']
0
1
2
3
4
5
6
7
8
9
0 1
['1', '2', '3', '4', '5', '6', '7', '8', '9']
1
2
3
4
5
6
7
8
9
Traceback (most recent call last):
  File "testbtopen.py", line 13, in ?
    i   =       db.first()[0]
  File "/usr/lib/python2.4/site-packages/PIL/__init__.py", line 269, in first

  File "/usr/lib/python2.4/site-packages/PIL/__init__.py", line 183, in _checkCursor

_bsddb.DBNotFoundError: (-30989, 'DB_NOTFOUND: No matching key/data pair found')
msg32138 - (view) Author: Neal Norwitz (nnorwitz) * (Python committer) Date: 2007-05-28 00:51
Duplicate of 1725856.
History
Date User Action Args
2022-04-11 14:56:24adminsetgithub: 45004
2007-05-27 05:15:37quixocreate