[Python-Dev] We got leaks!
Kevin Jacobs
jacobs@penguin.theopalgroup.com
Fri, 6 Dec 2002 18:09:48 -0500 (EST)
First minimal test case:
class Leaker(object):
def __hash__(self): return 1
for i in range(10):
hash( Leaker() )
print '*' * 10, 'total refs:', sys.gettotalrefcount()
In the context of the datetime objects, this leak only affects the Python
version. It also requires that the Leaker class is a new-style object.
I'm in the process of isolating the other leak that hits both the Python and
C verions of datetime in the test_pickling() function, though I suspect that
may be other incarnations of the above problem.
Fun, fun!
-Kevin
--
Kevin Jacobs
The OPAL Group - Enterprise Systems Architect
Voice: (216) 986-0710 x 19 E-mail: jacobs@theopalgroup.com
Fax: (216) 986-0714 WWW: http://www.theopalgroup.com