NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
Packagist
Packagist, #553 most downloaded on Packagist
General-purpose collections pipeline
Latest stable
v6.8.1
Last release 1 months ago
30 Sep 2026
Ships unpredictably
gaps range from 2 weeks to 7 months
Nearly every release is documented
notes for 57 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
9 years old
73 releases · first in 2017
Drag across the ruler to compare, or tap a release to open it.
Augment fold() and reduce() with type variables by @sanmai in https://github.com/sanmai/pipeline/pull/132
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.8...v6.8.1
slice() handled arrays and generators well, but on other iterators it didn't do so well. Not anymore.
slice() handled arrays and generators well, but on other iterators it didn't do so well. Not anymore.
Code style fixes to reflect coding standards coming in 6.x
Code style fixes to reflect coding standards coming in 6.x
Your coding agent can read these notes before it upgrades. Set up the MCP server →
New slice() method, works like \array_slice() but with lazily (see https://github.com/sanmai/pipeline/pull/90)
slice() method, works like \array_slice() but with lazily (see https://github.com/sanmai/pipeline/pull/90)Tested to work on PHP 7.1 - 8.1.
Tested to work on PHP 7.1 - 8.1.
Nothing published for this version
Minor code style fixes. This will be the last release of this branch (hopefully).
Minor code style fixes. This will be the last release of this branch (hopefully).
This is a maintenance release to serve as a point of reference.
This is a maintenance release to serve as a point of reference.
This release is fully backward-compatible with the previous major version: tests are all the same and passing.
...With typed properties.
This release is fully backward-compatible with the previous major version: tests are all the same and passing.
Nothing published for this version
Minor code style fixes. This will be the last release of this branch (hopefully).
Minor code style fixes. This will be the last release of this branch (hopefully).
This is a maintenance release to serve as a point of reference. Changes include removed redundant PHPDoc, additional test.
This is a maintenance release to serve as a point of reference. Changes include removed redundant PHPDoc, additional test.
We won't be removing it in the next version, hence the next version is the version where this should be deprecated.
We won't be removing it in the next version, hence the next version is the version where this should be deprecated.
It should be a tiny bit faster with native function invocations.
It should be a tiny bit faster with native function invocations.
Previously deprecated Pipeline\fromArray() has some merit as it explicitly wants an array, not just any iterable. Which is a good thing if you want to…
Previously deprecated Pipeline\fromArray() has some merit as it explicitly wants an array, not just any iterable. Which is a good thing if you want to be sure that you're passing an array, and only.
Minor code style fixes. This will be the last release of this branch (hopefully).
Minor code style fixes. This will be the last release of this branch (hopefully).
This is a maintenance release to serve as a point of reference. Changes include simplified PHPDoc, one else less, additional tests.
This is a maintenance release to serve as a point of reference. Changes include simplified PHPDoc, one else less, additional tests.
It should be a tiny bit faster with native function invocations.
It should be a tiny bit faster with native function invocations.
All native functions are now called from within the root namespace.
null comparison used.Not much of a change, but static analyzers must be tiny bit more happy.
Not much of a change, but static analyzers must be tiny bit more happy.
Nothing published for this version
Minor code style fixes. This will be the last release of this branch (hopefully).
Minor code style fixes. This will be the last release of this branch (hopefully).
All native functions are now called from within the root namespace.
null comparison used.Not much of a change, but static analyzers must be tiny bit more happy.
Not much of a change, but static analyzers must be tiny bit more happy.
Fixed a bug where filter() wouldn't work on some types of iterators.
filter() wouldn't work on some types of iterators.Minor code style fixes. This will be the last release of this branch (hopefully).
Minor code style fixes. This will be the last release of this branch (hopefully).
This is a maintenance release to serve as a point of reference. Changes include removed redundant PHPDoc, simplified code, and backported additional t
This is a maintenance release to serve as a point of reference. Changes include removed redundant PHPDoc, simplified code, and backported additional tests.
Maintenance release to serve as a point of reference. Other than that nothing really changed.
Maintenance release to serve as a point of reference. Other than that nothing really changed.
Added Pipeline\Standard as an alias for Simple.
Pipeline\Standard as an alias for Simple.Now the PHP 5.6-compatible version can be used almost in the same way as the more recent versions.
unpack() should now properly work with iterators.
unpack() should now properly work with iterators.Backported entry point functions from the current release.
unpack() and toArray()Other than for specific interface names, this version should now be usable interchangeable with the most current ones.
Improve PHP-CS-Fixer configuration by @sanmai in https://github.com/sanmai/pipeline/pull/134
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.8.1...v6.9
Add skipWhile() by @sanmai in https://github.com/sanmai/pipeline/pull/130
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.7...v6.8
Add toArrayPreservingKeys by @sanmai in https://github.com/sanmai/pipeline/pull/126
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.6...v6.7
Introduce Welford's online algorithm for variance by @sanmai in https://github.com/sanmai/pipeline/pull/116
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.5...v6.6
It is time to stop supporting PHP <=7.3 by @sanmai in https://github.com/sanmai/pipeline/pull/117
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.4...v6.5
Add flatten(), a readable shortcut for unpack() by @sanmai in https://github.com/sanmai/pipeline/pull/114
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.3...v6.4
Add chunk() by @sanmai in https://github.com/sanmai/pipeline/pull/110
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.2...v6.3
Introduce append(), prepend(), push(), unshift() by @sanmai in https://github.com/sanmai/pipeline/pull/108
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.1...v6.2
Improve test coverage by @sanmai in https://github.com/sanmai/pipeline/pull/144
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.10...v6.11
Add/min max by @sanmai in https://github.com/sanmai/pipeline/pull/142
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.9...v6.10
Reservoir sampling by @sanmai in https://github.com/sanmai/pipeline/pull/93
Full Changelog: https://github.com/sanmai/pipeline/compare/v6.0.1...v6.1
This release comes with a significant change: the main class is no longer final or otherwise locked. Conversely, there are no intermediary classes and
This release comes with a significant change: the main class is no longer final or otherwise locked. Conversely, there are no intermediary classes and no interfaces as they are no longer required. If we won't need to update interfaces for every new method added, we won't need a major version every time we do that. Otherwise put, no more BC breaks for new methods!
Added zip(), used to merge several iterable types side by side.
zip(), used to merge several iterable types side by side.cast(), a simplified one-to-one mapper.toArray() will now preserve keys if requested.Countable.map() will try to preserve keys.fold() is a synonym to reduce() with reversed order of arguments.BC breaks:
PrincipalPipeline interface is no longer.Principal class is no longer public.Deprecated fromArray() to simplify the API as take() can do as much
else and continue in the code.fromArray() to simplify the API as take() can do as muchAlso because of that Pipeline\fromArray() became useless and is tagged for deprecation in favour of take(). Still available for API compatibility.
All familiar functions and interfaces, but with iterable type hints all over the place.
As a consequence, Pipeline\take() can now take not only iterators, but plain old arrays too. Arrays are handled eagerly, which is a point to keep in mind. For example:
$foo = take([0, 0, 1, 2, 3])->filter();
// at this point $foo contains exactly [1, 2, 3]
Also because of that Pipeline\fromArray() became useless and is tagged for deprecation in favour of take(). Still available for API compatibility.
Speaking of API compatibility, all previous code should work just as fine.
Previously deprecated Simple class is now gone. Use Standard instead.
map(), take(), and fromArray() are at your service.Simple class is now gone. Use Standard instead.map() doesn't require a callback now, passes through without it (a callback can be a null).filter() now won't fail on certain types of iterators.Simple is still there, but marked for deprecation.
The pipeline now comes in two variants: concrete Standard and abstract Principal.
Simple is still there, but marked for deprecation.
As usual for SPL, there's no guarantee keys would stay the same.
As usual for SPL, there's no guarantee keys would stay the same.
Extend select() with onReject hook by @sanmai in https://github.com/sanmai/pipeline/pull/288
Full Changelog: https://github.com/sanmai/pipeline/compare/7.8...7.9
feat: Add select() as primary method, filter() becomes alias by @sanmai in https://github.com/sanmai/pipeline/pull/285
Full Changelog: https://github.com/sanmai/pipeline/compare/7.7...7.8
Fix test deprecations by @sanmai in https://github.com/sanmai/pipeline/pull/270
Full Changelog: https://github.com/sanmai/pipeline/compare/7.6...7.7
Add cursor() by @sanmai in https://github.com/sanmai/pipeline/pull/266
Full Changelog: https://github.com/sanmai/pipeline/compare/7.5...7.6
Make peek() return Pipeline for fluent API by @sanmai in https://github.com/sanmai/pipeline/pull/261
Full Changelog: https://github.com/sanmai/pipeline/compare/7.4...7.5
peek() returns the first N items by @sanmai in https://github.com/sanmai/pipeline/pull/256
peek() returns the first N items by @sanmai in https://github.com/sanmai/pipeline/pull/256Full Changelog: https://github.com/sanmai/pipeline/compare/7.3...7.4
Add chunkBy() by @sanmai in https://github.com/sanmai/pipeline/pull/251
chunkBy() by @sanmai in https://github.com/sanmai/pipeline/pull/251Full Changelog: https://github.com/sanmai/pipeline/compare/7.2...7.3
PHP 8.5 support by @sanmai in https://github.com/sanmai/pipeline/pull/239
Full Changelog: https://github.com/sanmai/pipeline/compare/7.1...7.2
fix: Ensure skipWhile() stops calling the predicate once match is found by @sanmai in https://github.com/sanmai/pipeline/pull/338
Full Changelog: https://github.com/sanmai/pipeline/compare/7.11...7.12
Add collect() by @sanmai in https://github.com/sanmai/pipeline/pull/332
Full Changelog: https://github.com/sanmai/pipeline/compare/7.10...7.11
Ensure zip() operates eagerly with arrays by @sanmai in https://github.com/sanmai/pipeline/pull/325
Full Changelog: https://github.com/sanmai/pipeline/compare/7.9...7.10
One column per quarter.