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.

Title: gdbm needs to be iterable
Type: Stage:
Components: Library (Lib) Versions: Python 2.6
Status: closed Resolution: accepted
Dependencies: Superseder:
Assigned To: rhettinger Nosy List: facundobatista, nnorwitz, rhettinger, therve
Priority: high Keywords: patch

Created on 2008-02-23 15:26 by therve, last changed 2022-04-11 14:56 by admin. This issue is now closed.

File name Uploaded Description Edit
dbm.diff therve, 2008-02-24 09:19
gdbm.diff therve, 2008-02-24 09:19
Messages (6)
msg62749 - (view) Author: Thomas Herve (therve) * Date: 2008-02-23 15:26
A recent change in shelve (r60927) raises the need for gdbm objects to
be iterable. We can see it by running test_shelve on a machine with
gdbm. I'll try to fix this.

The same thing should be done with the dbm module I think.
msg62890 - (view) Author: Thomas Herve (therve) * Date: 2008-02-24 09:20
Attached files add contains method to dbm and gdbm objects. It fixes
failures with test_shelve. I'm ready to add more tests for this, but
#1960 should probably go in first (it converts the tests to unittest,
and add some coverage).

Please review!
msg62891 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2008-02-24 09:30
The patch looks good to my eye, but I can't test it directly.  Will 
apply and see what the buildbots think about it.
msg63008 - (view) Author: Neal Norwitz (nnorwitz) * (Python committer) Date: 2008-02-25 22:33
Thomas, thanks for fixing this.  I didn't see any specific problems with
the patch, but I'm wondering why the code doesn't just call has_key in
both cases?
msg63009 - (view) Author: Facundo Batista (facundobatista) * (Python committer) Date: 2008-02-25 22:35
Applied in r61072. 

Raymond, I stole this from you, because I had the same conclusion and it
was very needed for the buildbot.

Thank you all!
msg63015 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2008-02-25 23:13
Date User Action Args
2022-04-11 14:56:31adminsetgithub: 46421
2008-02-25 23:13:04rhettingersetmessages: + msg63015
2008-02-25 22:35:04facundobatistasetstatus: open -> closed
nosy: + facundobatista
resolution: accepted
messages: + msg63009
2008-02-25 22:33:42nnorwitzsetnosy: + nnorwitz
messages: + msg63008
2008-02-24 09:31:03rhettingersetassignee: rhettinger
2008-02-24 09:30:25rhettingersetpriority: high
nosy: + rhettinger
messages: + msg62891
2008-02-24 09:20:55thervesetmessages: + msg62890
2008-02-24 09:19:21thervesetfiles: + gdbm.diff
2008-02-24 09:19:13thervesetfiles: + dbm.diff
keywords: + patch
2008-02-23 15:26:06thervecreate