Monorepo for tools developed by the Rush Stack community
Installations
npm install @rushstack/stream-collator
Developer Guide
Typescript
No
Module System
CommonJS
Node Version
20.18.1
NPM Version
10.8.2
Score
96.6
Supply Chain
87.7
Quality
95.4
Maintenance
100
Vulnerability
99.3
License
Releases
Unable to fetch releases
Contributors
Languages
TypeScript (96.31%)
JavaScript (3.37%)
SCSS (0.16%)
Shell (0.05%)
HTML (0.05%)
CSS (0.03%)
Sass (0.03%)
Batchfile (0.01%)
Developer
Download Statistics
Total Downloads
43,339,643
Last Day
34,209
Last Week
251,141
Last Month
750,786
Last Year
14,562,141
GitHub Statistics
6,018 Stars
22,255 Commits
609 Forks
54 Watching
107 Branches
279 Contributors
Bundle Size
327.03 kB
Minified
91.09 kB
Minified + Gzipped
Package Meta Information
Latest Version
4.1.81
Package Id
@rushstack/stream-collator@4.1.81
Unpacked Size
375.12 kB
Size
39.32 kB
File Count
23
NPM Version
10.8.2
Node Version
20.18.1
Publised On
09 Jan 2025
Total Downloads
Cumulative downloads
Total Downloads
43,339,643
Last day
-23.5%
34,209
Compared to previous day
Last week
-1.3%
251,141
Compared to previous week
Last month
-34.1%
750,786
Compared to previous month
Last year
1.1%
14,562,141
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
Dependencies
2
Dev Dependencies
2
@rushstack/stream-collator
This library enables a tool to display live console output from multiple concurrent processes, while ensuring that their output does not get jumbled together.
How does it work?
The stream-collator manages the output of these streams, ensuring that no two streams are writing to the console at the same time. At any given time, one stream registered with the collator is the active stream, which means that particular stream will be live streaming, while the others will wait for that stream to finish before their output is displayed.
For example, if you have 3 streams (e.g. from using child_process.spawn()
).
Stream A will write: AAAAA
Stream B will write: BBBBBBBBBBBBBBBBBBBB
Stream C will write: CCCCCCCCCC
If these streams are all being piped directly to stdout (without @rushstack/stream-collator
), you could end up
with jumbled output:
ABACCCBCCCCBBABBCBBABBBBBBCCAB
Something like the following would be much more useful to users of your application:
AAAAABBBBBBBBBBBBBBBCCCCCCCCCC
This is where the @rushstack/stream-collator
comes in!
The active stream
At any given time, a single stream is designated as the active stream. The output of the active stream will always be live-streamed. This is particularly useful for long-running streams. When the active stream finishes, a new stream is selected as the active stream and all of its contents up to that point will be emitted. Whenever an active stream finishes, all background streams which have been completed will be emitted.
Usage
🚨 This is an early preview release. Please report issues! 🚨
WITH VERSION 4.X, THIS PACKAGE HAS BEEN REDESIGNED TO USE THE NEW @rushstack/terminal SYSTEM. IN THE NEXT RELEASE, THE
CollatedTerminal
API WILL BE REPLACED WITH THETerminal
API.The usage instructions will be updated once that refactoring is complete.
Links
- CHANGELOG.md - Find out what's new in the latest version
- API Reference
@rushstack/stream-collator
is part of the Rush Stack family of projects.
No vulnerabilities found.
Reason
30 commit(s) and 15 issue activity found in the last 90 days -- score normalized to 10
Reason
security policy file detected
Details
- Info: security policy file detected: SECURITY.md:1
- Info: Found linked content: SECURITY.md:1
- Info: Found disclosure, vulnerability, and/or timelines in security policy: SECURITY.md:1
- Info: Found text in security policy: SECURITY.md:1
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Warn: project license file does not contain an FSF or OSI license.
Reason
Found 12/30 approved changesets -- score normalized to 4
Reason
dependency not pinned by hash detected -- score normalized to 3
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:43: update your workflow using https://app.stepsecurity.io/secureworkflow/microsoft/rushstack/ci.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:54: update your workflow using https://app.stepsecurity.io/secureworkflow/microsoft/rushstack/ci.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:80: update your workflow using https://app.stepsecurity.io/secureworkflow/microsoft/rushstack/ci.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/file-doc-tickets.yml:26: update your workflow using https://app.stepsecurity.io/secureworkflow/microsoft/rushstack/file-doc-tickets.yml/main?enable=pin
- Warn: npmCommand not pinned by hash: .devcontainer/setup.sh:12
- Info: 0 out of 4 GitHub-owned GitHubAction dependencies pinned
- Info: 1 out of 1 third-party GitHubAction dependencies pinned
- Info: 0 out of 1 npmCommand dependencies pinned
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: no topLevel permission defined: .github/workflows/ci.yml:1
- Warn: no topLevel permission defined: .github/workflows/file-doc-tickets.yml:1
- Info: no jobLevel write permissions found
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 13 are checked with a SAST tool
Reason
24 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-qwcr-r2fm-qrc7
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
- Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-434g-2637-qmqr
- Warn: Project is vulnerable to: GHSA-49q7-c7j4-3p7m
- Warn: Project is vulnerable to: GHSA-977x-g7h5-7qgw
- Warn: Project is vulnerable to: GHSA-f7q4-pwc6-w24p
- Warn: Project is vulnerable to: GHSA-fc9h-whq2-v747
- Warn: Project is vulnerable to: GHSA-3fjj-p79j-c9hh
- Warn: Project is vulnerable to: GHSA-c7qv-q95q-8v27
- Warn: Project is vulnerable to: GHSA-2p57-rm9w-gvfp
- Warn: Project is vulnerable to: GHSA-36fh-84j7-cv5h
- Warn: Project is vulnerable to: GHSA-76p3-8jx3-jpfq
- Warn: Project is vulnerable to: GHSA-3rfm-jhwj-7488
- Warn: Project is vulnerable to: GHSA-hhq3-ff78-jv3g
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
- Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55
- Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w
- Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j
- Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg
- Warn: Project is vulnerable to: GHSA-w5p7-h5w8-2hfq
- Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q
- Warn: Project is vulnerable to: GHSA-776f-qx25-q3cc
Score
5.1
/10
Last Scanned on 2025-01-13
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More