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.

classification
Title: fix reliance on refcounting in test_weakref
Type: behavior Stage: resolved
Components: Versions: Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: alex, bdkearns, python-dev
Priority: normal Keywords: patch

Created on 2014-08-24 21:32 by bdkearns, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
test_weakref.patch bdkearns, 2014-08-24 21:32
Messages (4)
msg225839 - (view) Author: Brian Kearns (bdkearns) * Date: 2014-08-24 21:32
The test fails on Python implementations with non-refcounted GCs without these lines. Should go on py3k branches also.
msg225840 - (view) Author: Alex Gaynor (alex) * (Python committer) Date: 2014-08-24 21:33
Perhaps these should use the gc_collect function in test_support?
msg225841 - (view) Author: Brian Kearns (bdkearns) * Date: 2014-08-24 21:41
Possibly. But if so then one would argue there are plenty of other instances where gc_collect "should" be used, both within test_weakref and the rest of the test suite. Chose gc.collect here as it was used all over test_weakref.py, gc_collect never being used, and it fixed the test on PyPy.
msg225845 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2014-08-24 23:05
New changeset b63b8c5628da by Benjamin Peterson in branch '2.7':
fix some test_weakref tests to not rely on ref-counting (closes #22267)
http://hg.python.org/cpython/rev/b63b8c5628da

New changeset b1c82ef96862 by Benjamin Peterson in branch '3.4':
fix some test_weakref tests to not rely on ref-counting (closes #22267)
http://hg.python.org/cpython/rev/b1c82ef96862

New changeset 294b598afbb6 by Benjamin Peterson in branch 'default':
merge 3.4 (#22267)
http://hg.python.org/cpython/rev/294b598afbb6
History
Date User Action Args
2022-04-11 14:58:07adminsetgithub: 66463
2014-08-24 23:05:18python-devsetstatus: open -> closed

nosy: + python-dev
messages: + msg225845

resolution: fixed
stage: resolved
2014-08-24 21:41:48bdkearnssetmessages: + msg225841
2014-08-24 21:33:26alexsetnosy: + alex
messages: + msg225840
2014-08-24 21:32:46bdkearnscreate