Registry / data / functional-streams

functional-streams

JSON →
library1.6.4pypypi✓ verified 89d ago

A Python library that provides functional programming stream operations similar to Java streams, enabling declarative, concise data transformations via lazy evaluation, fluent chaining, and common operations like map, filter, reduce, and more. Current version 1.6.4, supports Python >=3.6, with moderate release cadence (minor updates every few months).

pip install functional-streams
INSTALL
IMPORT
SIG · FUNCTIONAL-STREAMS
F
functional-streams
datapythonv1.6.4
Install
1.5s avg
Import
—
Disk
16MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.9–3.13
musl
3.9–3.13
Install & Compatibility
Where this runs
tested against v1.6.4 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 0.000s · 17.9MB
glibc
py 3.10–3.95 runs
installs and imports cleanly · install 1.5s · import 0.000s · 18MB
16MB installed
● package 16MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Stream
✓ from streams import Stream
✗ from functional.streams import Stream

Create a stream from a list, filter even numbers, double them, and collect to list.

from functional.streams import Stream result = (Stream([1, 2, 3, 4]) .filter(lambda x: x % 2 == 0) .map(lambda x: x * 2) .to_list()) print(result) # [4, 8]
Debug
Known issues
gotchaStream operations are lazy; a 'terminal' operation like to_list() or sum() is required to trigger evaluation. Without a terminal operation, nothing will execute.
fix
Always call a terminal operation (to_list(), first(), reduce(), etc.) at the end of your stream pipeline.
affects: all
gotchaStreams are single-use: once a terminal operation is called, the stream cannot be reused. Attempting to do so will raise a RuntimeError.
fix
Create a new stream for each pipeline. If you need to reuse data, store intermediate results in a list.
affects: all
deprecatedThe 'streams' module (lower-level) is considered deprecated in favor of 'functional.streams' (higher-level). Using old imports may lead to compatibility issues in future versions.
fix
Use 'from functional.streams import Stream' instead of 'from streams import Stream'.
affects: < 1.6
Upgrade
Version history
1.6.4latest on PyPI · released Jul 14, 2021
Audit
Dependencies

No dependency data recorded yet.

Agent activity
2 hits · last 30 days
node
2
Resources
functional-streams — pip install functional-streams · libregistry