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
dbm.ndbm already has get(). dbm.gnu is missing it.
Kain94 commented on Aug 1, 2010
Kain94mannequin
MannequinAuthor
More actions
Yes I know, that's why get() should be a standard dbm's method like __getitem__() and __setitem__(). So, defining it in all classes which implements dbm interface would be a good enhancement.
ysjray commented on Aug 2, 2010
ysjraymannequin
Mannequin
More actions
+1 on generalize the dbm.gnu and gbm.ndbm, and also dbm.dumb. All of them should follow the Collections.MutableMapping ABC. I will work out a patch to fix this.
Activity
Kain94 commentedon May 6, 2010
I'm suggesting to add the dict's 'get' method to dbm interface. So that, it would be easier to manage 'key not found' issues.
B. Venelle.
[-][PATCH] get method for dbm interface[/-][+]get method for dbm interface[/+]birkenfeld commentedon Aug 1, 2010
dbm.ndbm already has get(). dbm.gnu is missing it.
Kain94 commentedon Aug 1, 2010
Yes I know, that's why get() should be a standard dbm's method like __getitem__() and __setitem__(). So, defining it in all classes which implements dbm interface would be a good enhancement.
ysjray commentedon Aug 2, 2010
+1 on generalize the dbm.gnu and gbm.ndbm, and also dbm.dumb. All of them should follow the Collections.MutableMapping ABC. I will work out a patch to fix this.
ysjray commentedon Aug 5, 2010
See bpo-9523.
merwok commentedon Nov 12, 2010
The other bug report adds the get method as part of MutableMapping compliance, so I’m closing this as a obsoleted.