NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
PyPI · #125 most downloaded on PyPI
More routines for operating on iterables, beyond itertools
Last release 4 months ago
22 May 2026
Ships fairly regularly
a new release about every 4 months
Most releases are documented
notes for 36 of 54 stable releases
1 version withdrawn
withdrawn after publishing
14 years old
55 releases · first in 2012
numeric_range was updated to fix its handling of empty ranges (thanks to rhettinger)
Changes:
numeric_range was updated to fix its handling of empty ranges (thanks to rhettinger)peekable was updated to fix typing issues (thanks to DORI2001, powellnorma, Pandede, m9810223, and rhettinger)islice_extended was optimized for memory usage and speed (thanks to ben42code, rhettinger, and pochmann)serialize now supports the generator methods throw, send, and close (thanks to rhettinger)seekable now supports implements __getitem__ for cached elements (thanks to SAY-5, jenstroeger, and JamesParrott)zip_equal was removed in 11.0.0. It had been deprecated and raising DeprecationWarning since 2021, but it's removal shoul have been documented in 11.0…
always_iterable in 11.0.0 have been reverted due to reported problems (thanks to ngoldbaum and rhettinger)zip_equal was removed in 11.0.0. It had been deprecated and raising DeprecationWarning since 2021, but it's removal shoul have been documented in 11.0.0's release notes. We regret the error.running_statistics has been moved from more_itertools.more to more_itertools.recipes. Its docstring was also improved (thanks to mastash3ff and rhettinger)One column per quarter.
This release restores pairwise, which was mistakenly removed in 11.0.0 instead of being deprecated. It is now marked as deprecated and will be removed…
This release restores pairwise, which was mistakenly removed in 11.0.0 instead of being deprecated. It is now marked as deprecated and will be removed in a future major release. Use itertools.pairwise as a replacement.
callback_iter is deprecated. It will be removed in a future major release.
callback_iter is deprecated. It will be removed in a future major release.iequals no longer returns True when called with ([], [ANY]) (thanks to rhettinger and pochmann3)pred argument for locate and replace must now be able to
handle a variable number of arguments. See their docstrings for details. (thanks to veeceey, james-wasson, and pochmann3)unique_everseen now raises TypeError when input elements are not hashable.
The silent fallback mechanism for unhashable inputs has been removed. (thanks to rhettinger and karlicoss)windowed now raises ValueError when given a window size of 0 (thanks to rhettinger and brevzin)flatten, iter_except, repeatfunc, prepend, transpose,
and sum_of_squares have been changed. Code that uses these functions will need to be updated if it
uses keywords for positional arguments. (thanks to rhettinger)concurrent_tee: similar to tee, but with guaranteed threading
semantics (thanks to rhettinger)random_derangement: returns a random derangement of elements from an
iterable (thanks to rhettinger)running_mean: yields the mean of values in an iterable, or in a sliding
window (thanks to rhettinger)running_statistics: provides statistics for the values in an iterable, or
in a sliding window (thanks to rhettinger)serialize: wraps a non-concurrent iterator with a lock to enforce
sequential access (thanks to rhettinger)synchronized: wraps an iterator-returning callable to make its iterators
thread-safe (thanks to rhettinger)sized_iterator: wraps an iterable with a known length and implements __len__ (thanks to assaf127)always_iterable were improved (thanks to rhettinger and maltevesper)callback_iter was fixedexactly_n's handling of negative arguments was fixed (thanks to rhettinger)extract`` now accepts a monotonic` argument for improved performance (thanks to rhettinger)numeric_range's handling of negative steps was fixed (thanks to bysiber)grouper implementation was updated to match the itertools docs (thanks to rhettinger)nth_product, product_index, gray_product,
partial_product, nth_product, product_index, and
random_product now accept a repeat keyword argument (thanks to rhettinger)powerset_of_sets can now construct frozenset instances (thanks to rhettinger)stagger were improved (thanks to nathanjmcdougall)partition was improved (thanks to rhettinger and yueyinqiu)count_cycle, difference,
random_product, was improved nth_combination, nth_combination_with_replacement,
nth_permuwas improvedtation, nth_product, product_index,
random_permutation, substrings, and value_chain was
improved (thanks to rhettinger)ichunked was improved (thanks to pochmann3 and rhettinger)Fix typo in version history for 10.7.0 by bbayles in https://github.com/more-itertools/more-itertools/pull/981
derangements by itself by bbayles in https://github.com/more-itertools/more-itertools/pull/985interleave_longest by pochmann3 in https://github.com/more-itertools/more-itertools/pull/1027mark_ends by pochmann3 in https://github.com/more-itertools/more-itertools/pull/1035unzip: replace custom itemgetter by pochmann3 in https://github.com/more-itertools/more-itertools/pull/1059interleave_randomly by ktbarrett in https://github.com/more-itertools/more-itertools/pull/1048Full Changelog: https://github.com/more-itertools/more-itertools/compare/v10.7.0...v10.8.0
derangements by itself by bbayles in #985interleave_longest by pochmann3 in #1027mark_ends by pochmann3 in #1035unzip: replace custom itemgetter by pochmann3 in #1059interleave_randomly by ktbarrett in #1048Full Changelog: v10.7.0...v10.8.0
See the change log here for details.
See the change log here for details.
is_prime and nth_prime were added (thanks to JamesParrott and rhettinger)
New functions:
is_prime and nth_prime were added (thanks to JamesParrott and rhettinger)loops was added (thanks to rhettinger)Changes to existing functions:
factor was optimized to handle larger inputs and use less memory (thanks to rhettinger)spy was optimized to enable nested calls (thanks to rhettinger)polynomial_from_roots was made non-recursive and able to handle larger numbers of roots (thanks to pochmann3 and rhettinger)is_sorted now only relies on less than comparisons (thanks to rhettinger)outer_product was improved (thanks to rhettinger)sample were improved (thanks to rhettinger)Other changes:
mypy checks were fixed (thanks to JamesParrott)Optimize all_equal recipe by @bbayles in #899
Issue 854: sample improvements by @bbayles in https://github.com/more-itertools/more-itertools/pull/855
windowed_complete corrected by @m472 in https://github.com/more-itertools/more-itertools/pull/881zip_broadcast by @Pandede in https://github.com/more-itertools/more-itertools/pull/888strict to sort_together by @Pandede in https://github.com/more-itertools/more-itertools/pull/892Full Changelog: https://github.com/more-itertools/more-itertools/compare/v10.3.0...v10.4.0
windowed_complete corrected by @m472 in #881zip_broadcast by @Pandede in #888strict to sort_together by @Pandede in #892Full Changelog: v10.3.0...v10.4.0
100% Code Coverage by @haukex in https://github.com/more-itertools/more-itertools/pull/792
collapse by @james-wasson in https://github.com/more-itertools/more-itertools/pull/796padded by @james-wasson in https://github.com/more-itertools/more-itertools/pull/805ichunked by @james-wasson in https://github.com/more-itertools/more-itertools/pull/793chunked_even itertool by @james-wasson in https://github.com/more-itertools/more-itertools/pull/816Full Changelog: https://github.com/more-itertools/more-itertools/compare/v10.2.0...v10.3.0
collapse by @james-wasson in #796padded by @james-wasson in #805ichunked by @james-wasson in #793chunked_even itertool by @james-wasson in #816Full Changelog: v10.2.0...v10.3.0
iter_suppress (thanks to jaraco, pochmann, and rhettinger)
New functions
iter_suppress (thanks to jaraco, pochmann, and rhettinger)filter_map (thanks to struktured)classify_unique (thanks to haukex)totient (from the itertools docs)reshape (from the itertools docs)Changes to existing functions
factor, iter_index, sieve, and unique_justseen were updated to match the itertools docsfirst was was optimized (thanks to pochmann)takewhile_inclusive was was refactored (thanks to eltoder)combination_with_replacement_index was was optimized (thanks to elliotwutingfeng and rhettinger)nth_permutation, nth_combination_with_replacement, combination_index, and combination_with_replacement_index were optimized (thanks to rhettinger)batched now accepts a strict argument (adapted from itertools docs)time_limited was improved for Windows (thanks to haukex)Other changes
Add more tests for zip_broadcast() by @kalekundert in https://github.com/more-itertools/more-itertools/pull/739
zip_broadcast() by @kalekundert in https://github.com/more-itertools/more-itertools/pull/739zip_broadcast() by pre-filling the scalar elements by @kalekundert in https://github.com/more-itertools/more-itertools/pull/740zip_broadcast by @pochmann in https://github.com/more-itertools/more-itertools/pull/742_zip_equal by @pochmann in https://github.com/more-itertools/more-itertools/pull/744Full Changelog: https://github.com/more-itertools/more-itertools/compare/v10.0.1...v10.1.0
Update recipes.iter_index to match CPython PR 102360 by @bbayles in https://github.com/more-itertools/more-itertools/pull/690
iterate() to enable func to raise StopIteration + 3 unittests by @jrebiffe in https://github.com/more-itertools/more-itertools/pull/708partition by @pochmann in https://github.com/more-itertools/more-itertools/pull/710partial_product (also simplify and clean up) by @pochmann in https://github.com/more-itertools/more-itertools/pull/714pairwise by @pochmann in https://github.com/more-itertools/more-itertools/pull/712partial_product by @pochmann in https://github.com/more-itertools/more-itertools/pull/716duplicates_justseen by @pochmann in https://github.com/more-itertools/more-itertools/pull/718Full Changelog: https://github.com/more-itertools/more-itertools/compare/v9.1.1...v10.0.0
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
See the release notes.
See the release notes.
Nothing published for this version
Nothing published for this version
Nothing published for this version
See the release notes for details.
See the release notes for details.
See the changelog for details.
See the changelog for details.
See the release notes.
See the release notes.
See the changelog for details.
See the changelog for details.
See the release notes for details.
See the release notes for details.
See the release notes for details.
See the release notes for details.
See the release notes.
See the release notes.
See the release notes.
See the release notes for details.
See the release notes for details.
See the release notes for details.
See the release notes for details.
See the release notes for details.
See the release notes for details.
See the release notes for details.
See the release notes for details.
See the release notes for the full list of changes.
See the release notes for the full list of changes.
This is the first Python 3-only release.
This is the first Python 3-only release.
Python 2 users may use version 5.0.0.
See the release notes for the full list of changes.
Compare
Compare
This commit was created on GitHub.com and signed with GitHub’s verified signature . The key has expired.
cf660c3
This commit was created on GitHub.com and signed with GitHub’s verified signature . The key has expired.
GPG key ID: 4AEE18F83AFDEB23 Expired
Verified Learn about vigilant mode .
Merge pull request #225 from erikrose/version-4.3.0
Nothing published for this version
Nothing published for this version
See PR #180. Download from PyPI.
See PR #180. Download from PyPI.
See PR #175. Download from PyPI.
See PR #175. Download from PyPI.
See PR #150. Download from PyPI.
See PR #150. Download from PyPI.
See PR #141. Download from PyPI.
See PR #141. Download from PyPI.
See PR #123. Download from PyPI.
See PR #123. Download from PyPI.
See PR #119. Download from PyPI.
See PR #119. Download from PyPI.
See PR #104. Download from PyPI.
See PR #104. Download from PyPI.
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →