Éric Araujo mer...@netwok.org added the comment:
Excellent! I will apply this.
I looked through the rest of database.py and did not see any other
generators that appeared to erroneously hold a file handle open.
Me neither. Thanks for checking.
In addition there is one generator function
Roundup Robot devnull@devnull added the comment:
New changeset 2b9a0a091566 by Éric Araujo in branch 'default':
Close file handles in a timely manner in packaging.database (#12504).
http://hg.python.org/cpython/rev/2b9a0a091566
--
nosy: +python-dev
Éric Araujo mer...@netwok.org added the comment:
Thanks for that! I agree that it’s a fake optimization to work with generators
instead of lists when the list is small or when we depend on other resources
like file handles. There are a few methods we could change in the database
module.
Thomas Holmes tho...@devminded.com added the comment:
The output in my initial message is the output of the tests with them enabled
but pre database.py patch. Once the patch is applied all packaging tests that
run on my system pass.
I was 50/50 on whether or not to use the internal function
Thomas Holmes tho...@devminded.com added the comment:
Oh and thank you very much for your input. My apologies for the initial 9
e-mail spam when I created the issue, I bumbled the remote HG repository patch
generation :)
--
___
Python tracker
Thomas Holmes tho...@devminded.com added the comment:
I have made the change you suggested, creating a new list and simply amending
to minimize the diff. This new patch has been attached.
I looked through the rest of database.py and did not see any other generators
that appeared to
Changes by Thomas Holmes tho...@devminded.com:
Added file: http://bugs.python.org/file22612/6e15ba060803.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12504
___