@miso.ai/server-commons 0.6.3-beta.16 → 0.6.3-beta.18

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/package.json CHANGED
@@ -20,5 +20,5 @@
20
20
  "uuid": "^9.0.0",
21
21
  "yargs": "^17.5.1"
22
22
  },
23
- "version": "0.6.3-beta.16"
23
+ "version": "0.6.3-beta.18"
24
24
  }
@@ -24,12 +24,13 @@ export default class BufferedReadStream extends Readable {
24
24
  this._strategy.initialize(this, source);
25
25
  }
26
26
 
27
- async _construct() {
27
+ async _construct(done) {
28
28
  if (this._source.init) {
29
29
  this._debug(`[BufferedReadStream] init source start`);
30
30
  await this._source.init();
31
31
  this._debug(`[BufferedReadStream] init source done`);
32
32
  }
33
+ done();
33
34
  }
34
35
 
35
36
  async _read() {
@@ -35,13 +35,6 @@ export async function pipeline(...streams) {
35
35
  return new Promise((resolve, reject) => _pipeline(...streams.filter(s => s), err => err ? reject(err) : resolve()));
36
36
  }
37
37
 
38
- export async function pipelineToStdout(...streams) {
39
- return new Promise((resolve, reject) =>
40
- _pipeline(...streams, err => err ? reject(err) : resolve())
41
- .pipe(process.stdout, { end: false })
42
- );
43
- }
44
-
45
38
  export async function collect(stream) {
46
39
  const records = [];
47
40
  for await (const record of stream) {