[issue1502] itertools should grow chunkify

Raymond Hettinger report at bugs.python.org
Tue Nov 27 01:22:29 CET 2007


Raymond Hettinger added the comment:

Sorry, this has been proposed and rejected previously.  One of the 
reasons was that the docs already have a C-speed recipe, grouper(), 
that shows how to do it with padding and it is even simpler to do it 
without padding using only zip() or izip().  Another was a lack of 
compelling use cases.  It was more fun to write and discuss than 
actually use in real code.

Also, I'm not happy with the given implementation.  The name is weak 
and the "partial" argument complexifies the function (its often better 
to have separate function than two combine two behaviors with a flag 
variable).

Even if cleaned-up and a use case or two is demonstrated, am not 
willing to clutter the module with more functions like this.

That being said, I do want to compliment the submission of a working 
patch with unittests.  Nice work.

----------
assignee:  -> rhettinger
nosy: +rhettinger
resolution:  -> rejected
status: open -> closed

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1502>
__________________________________


More information about the Python-bugs-list mailing list