Movatterモバイル変換


[0]ホーム

URL:


homepage

Message257587

This issue trackerhas been migrated toGitHub, and is currentlyread-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Authormartin.panter
RecipientsArfrever, berker.peksag, ezio.melotti, martin.panter, python-dev, rhettinger, serhiy.storchaka, vstinner
Date2016-01-06.05:43:32
SpamBayes Score-1.0
Marked as misclassifiedYes
Message-id<1452059013.44.0.36419650146.issue22831@psf.upfronthosting.co.za>
In-reply-to
Content
I had another look at the five patches you mentioned. I made a couple review comments about expanding the scope of some “with” statements.There are a couple changes that add explicit file closing, where it was previously up to the garbage collector. I.e. code like open(...).read(). I think those changes are the most important, although they are scattered over the various patches.On the other hand, some of the changes in the test suite, particularly test_dbm_dumb.py and test_xmlrpc.py, hardly seem worth it. The main benefit of the “with” statement would be if the test code fails, which hopefully won’t happen that often. :)In the test suite, perhaps it would be better to call self.addCleanup(f.close) or similar in many cases. That way you wouldn’t need contextlib.closing() as much, and there would be less file history clutter and “cavern code”, due to the extra indentation.
History
DateUserActionArgs
2016-01-06 05:43:33martin.pantersetrecipients: +martin.panter,rhettinger,vstinner,ezio.melotti,Arfrever,python-dev,berker.peksag,serhiy.storchaka
2016-01-06 05:43:33martin.pantersetmessageid: <1452059013.44.0.36419650146.issue22831@psf.upfronthosting.co.za>
2016-01-06 05:43:33martin.panterlinkissue22831 messages
2016-01-06 05:43:32martin.pantercreate
Supported byThe Python Software Foundation,
Powered byRoundup
Copyright © 1990-2022,Python Software Foundation
Legal Statements

[8]ページ先頭

©2009-2026 Movatter.jp