classification
Title: regrtest says refleaks are "ok"
Type: behavior Stage: patch review
Components: Tests Versions: Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: benjamin.peterson, collinwinter, jyasskin
Priority: normal Keywords: patch

Created on 2009-05-14 22:28 by collinwinter, last changed 2009-05-15 01:59 by collinwinter. This issue is now closed.

Files
File name Uploaded Description Edit
refleak.patch collinwinter, 2009-05-14 22:36 Patch against trunk, r72643
Messages (3)
msg87776 - (view) Author: Collin Winter (collinwinter) * (Python committer) Date: 2009-05-14 22:28
Currently (r72643), regrtest.py -R:: says that a test passed even if it
leaked references:

trunk collinwinter$ ./python.exe Lib/test/regrtest.py -R::
test_urllib2_localnet
test_urllib2_localnet
beginning 9 repetitions
123456789
.........
test_urllib2_localnet leaked [3, 3, 3, 3] references, sum=12
1 test OK.
[50020 refs]
trunk collinwinter$

The attached patch turns that into

trunk collinwinter$ ./python.exe Lib/test/regrtest.py -R::
test_urllib2_localnet
test_urllib2_localnet
beginning 9 repetitions
123456789
.........
test_urllib2_localnet leaked [3, 3, 3, 3] references, sum=12
1 test failed:
    test_urllib2_localnet
[50010 refs]
trunk collinwinter$ echo $?
1
trunk collinwinter$

This makes it easier to run regrtest.py -R:: as part of a buildbot
installation.

I'll merge to py3k once this is reviewed. Any thoughts on merging to
release26-maint?
msg87779 - (view) Author: Benjamin Peterson (benjamin.peterson) * (Python committer) Date: 2009-05-14 23:17
That looks fine to me. I don't think it should be merged to any old
versions' branches, though.
msg87790 - (view) Author: Collin Winter (collinwinter) * (Python committer) Date: 2009-05-15 01:59
Applied in r72658 (trunk) and r72660 (py3k).
History
Date User Action Args
2009-05-15 01:59:59collinwintersetstatus: open -> closed
resolution: fixed
messages: + msg87790
2009-05-14 23:17:54benjamin.petersonsetnosy: + benjamin.peterson
messages: + msg87779
2009-05-14 22:36:33collinwintersetfiles: - refleak.patch
2009-05-14 22:36:26collinwintersetfiles: + refleak.patch
2009-05-14 22:28:32collinwintercreate