The gdbm module seems to have a memory leak.
The following code demonstrates it:
import gdbm
LargeNumber = 5000
d = gdbm.open ('testdbm', 'w', 0666)
i = 0
# this does not leak memory
while i < LargeNumber:
d[str(i)] = 'object %d' % i
i = i + 1
i = 0
# this does leak memory
while i < LargeNumber:
print d[str(i)]
i = i + 1
Does anyone have a fix?
Eric