[Python-Dev] [Python-checkins] r66321 - in python/trunk: Doc/library/warnings.rst Lib/asynchat.py Lib/bsddb/test/test_early_close.py Lib/mimetools.py Lib/test/test___all__.py Lib/test/test_exceptions.py Lib/test/test_hmac.py Lib/test/test_import.py Lib/test/test_macostools.py Lib/test/test_pep352.py Lib/test/test_py3kwarn.py Lib/test/test_random.py Lib/test/test_re.py Lib/test/test_struct.py Lib/test/test_structmembers.py Lib/test/test_sundry.py Lib/test/test_support.py Lib/test/test_symtable.py Lib/test/test_urllib.py Lib/test/test_urllibnet.py Lib/test/test_userstring.py Lib/test/test_warnings.py Lib/warnings.py Misc/NEWS
ncoghlan at gmail.com
Tue Sep 9 12:31:11 CEST 2008
M.-A. Lemburg wrote:
> On 2008-09-09 02:49, brett.cannon wrote:
>> Author: brett.cannon
>> Date: Tue Sep 9 02:49:16 2008
>> New Revision: 66321
>> warnings.catch_warnings() now returns a list or None instead of the custom
>> WarningsRecorder object. This makes the API simpler to use as no special object
>> must be learned.
>> Closes issue 3781.
>> Review by Benjamin Peterson.
> This sounds a lot like a feature.
> Why was it added just before RC1 ?
It's also a bug that was introduced by the late API changes made to
WarningsRecorder in r66135 (when WarningsRecorder was moved from
test.test_support to warnings to make it officially supported for use
outside the Python test suite, the API was also changed).
Instead of changing the API *again* could we please get the API reverted
back to the way it was for the two months prior to r66135 and only
change the location from test_support to warnings? (obviously, the use
of @contextmanager should still be removed since we don't particularly
want warnings to depend on contextlib).
Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
More information about the Python-Dev