@thi.ng/rstream 9.2.3 → 9.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -1
- package/README.md +1 -1
- package/nodejs.js +1 -1
- package/package.json +8 -8
- package/pubsub.js +1 -1
- package/subscription.js +4 -4
- package/tunnel.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
-
- **Last updated**: 2025-01-
|
|
3
|
+
- **Last updated**: 2025-01-14T12:23:33Z
|
|
4
4
|
- **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
|
|
5
5
|
|
|
6
6
|
All notable changes to this project will be documented in this file.
|
|
@@ -9,6 +9,12 @@ See [Conventional Commits](https://conventionalcommits.org/) for commit guidelin
|
|
|
9
9
|
**Note:** Unlisted _patch_ versions only involve non-code or otherwise excluded changes
|
|
10
10
|
and/or version bumps of transitive dependencies.
|
|
11
11
|
|
|
12
|
+
### [9.2.4](https://github.com/thi-ng/umbrella/tree/@thi.ng/rstream@9.2.4) (2025-01-14)
|
|
13
|
+
|
|
14
|
+
#### ♻️ Refactoring
|
|
15
|
+
|
|
16
|
+
- use optional chaining & nullish coalescing ([c5a0a13](https://github.com/thi-ng/umbrella/commit/c5a0a13))
|
|
17
|
+
|
|
12
18
|
## [9.2.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/rstream@9.2.0) (2024-12-05)
|
|
13
19
|
|
|
14
20
|
#### 🚀 Features
|
package/README.md
CHANGED
package/nodejs.js
CHANGED
|
@@ -3,7 +3,7 @@ import { stream } from "./stream.js";
|
|
|
3
3
|
const fromNodeJS = (stdout, stderr, close = true) => {
|
|
4
4
|
const ingest = stream();
|
|
5
5
|
stdout.on("data", (data) => ingest.next(data));
|
|
6
|
-
stderr
|
|
6
|
+
stderr?.on("data", (data) => ingest.error(data));
|
|
7
7
|
close && stdout.on("close", () => ingest.done());
|
|
8
8
|
return ingest;
|
|
9
9
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thi.ng/rstream",
|
|
3
|
-
"version": "9.2.
|
|
3
|
+
"version": "9.2.4",
|
|
4
4
|
"description": "Reactive streams & subscription primitives for constructing dataflow graphs / pipelines",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -45,13 +45,13 @@
|
|
|
45
45
|
},
|
|
46
46
|
"dependencies": {
|
|
47
47
|
"@thi.ng/api": "^8.11.16",
|
|
48
|
-
"@thi.ng/arrays": "^2.10.
|
|
49
|
-
"@thi.ng/associative": "^7.0.
|
|
50
|
-
"@thi.ng/atom": "^5.3.
|
|
51
|
-
"@thi.ng/checks": "^3.6.
|
|
48
|
+
"@thi.ng/arrays": "^2.10.10",
|
|
49
|
+
"@thi.ng/associative": "^7.0.19",
|
|
50
|
+
"@thi.ng/atom": "^5.3.17",
|
|
51
|
+
"@thi.ng/checks": "^3.6.19",
|
|
52
52
|
"@thi.ng/errors": "^2.5.22",
|
|
53
|
-
"@thi.ng/logger": "^3.0.
|
|
54
|
-
"@thi.ng/transducers": "^9.2.
|
|
53
|
+
"@thi.ng/logger": "^3.0.27",
|
|
54
|
+
"@thi.ng/transducers": "^9.2.13"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
|
57
57
|
"@microsoft/api-extractor": "^7.48.1",
|
|
@@ -223,5 +223,5 @@
|
|
|
223
223
|
],
|
|
224
224
|
"year": 2017
|
|
225
225
|
},
|
|
226
|
-
"gitHead": "
|
|
226
|
+
"gitHead": "6542b842120bef47cc18d45a1b1db68307a7f04b\n"
|
|
227
227
|
}
|
package/pubsub.js
CHANGED
package/subscription.js
CHANGED
|
@@ -102,7 +102,7 @@ class Subscription {
|
|
|
102
102
|
}
|
|
103
103
|
unsubscribeSelf() {
|
|
104
104
|
LOGGER.debug(this.id, "unsub self");
|
|
105
|
-
this.parent
|
|
105
|
+
this.parent?.unsubscribe(this);
|
|
106
106
|
this.state < State.UNSUBSCRIBED && (this.state = State.UNSUBSCRIBED);
|
|
107
107
|
this.release();
|
|
108
108
|
return true;
|
|
@@ -137,9 +137,9 @@ class Subscription {
|
|
|
137
137
|
}
|
|
138
138
|
error(e) {
|
|
139
139
|
const sub = this.wrapped;
|
|
140
|
-
const
|
|
141
|
-
|
|
142
|
-
return
|
|
140
|
+
const errorHandler = sub?.error;
|
|
141
|
+
errorHandler && LOGGER.debug(this.id, "attempting wrapped error handler");
|
|
142
|
+
return errorHandler?.(e) || this.unhandledError(e);
|
|
143
143
|
}
|
|
144
144
|
unhandledError(e) {
|
|
145
145
|
(LOGGER.parent !== NULL_LOGGER ? LOGGER : console).warn(
|
package/tunnel.js
CHANGED
|
@@ -51,7 +51,7 @@ class Tunnel extends Subscription {
|
|
|
51
51
|
if (this.terminate > 0) {
|
|
52
52
|
setTimeout(() => {
|
|
53
53
|
LOGGER.info("terminating workers...");
|
|
54
|
-
this.workers.forEach((worker) => worker
|
|
54
|
+
this.workers.forEach((worker) => worker?.terminate());
|
|
55
55
|
delete this.workers;
|
|
56
56
|
}, this.terminate);
|
|
57
57
|
}
|