@dxos/async 2.23.1-dev.ed17952c → 2.23.1-dev.f5b1145e

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.
@@ -1,6 +1,16 @@
1
- export function noop(...args: any[]): any[];
2
- export function sleep(timeout: any): Promise<unknown>;
3
- export function timeout(f: any, timeout?: number | undefined): Promise<unknown>;
4
- export function promiseTimeout(promise: Promise<any>, timeout: number, error: any): Promise<unknown>;
5
- export function waitForCondition(condFn: Function, timeout?: number | undefined, interval?: number | undefined): any;
1
+ /**
2
+ * Times out after delay.
3
+ */
4
+ export declare const sleep: (ms: number) => Promise<void>;
5
+ /**
6
+ * @param [timeout] How long to wait, in milliseconds (0 = no timeout).
7
+ */
8
+ export declare const promiseTimeout: <T = any>(promise: Promise<T>, timeout: number, error: Error) => Promise<T>;
9
+ /**
10
+ * Returns a Promise which resolves when `condFn` returns truthy. The value returned by
11
+ * `condFn` is used to resolve the Promise.
12
+ * @param [timeout] How long to wait, in milliseconds (0 = no timeout).
13
+ * @param [interval=10] How frequently to check, in milliseconds.
14
+ */
15
+ export declare const waitForCondition: (condFn: Function, timeout?: number, interval?: number) => Promise<any>;
6
16
  //# sourceMappingURL=async.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"async.d.ts","sourceRoot":"","sources":["../../src/async.js"],"names":[],"mappings":"AAOO,4CAA8B;AAO9B,qCAFM,QAAQ,OAAO,CAAC,CAgB3B;AAQK,+DAFM,QAAQ,OAAO,CAAC,CAa3B;AAOK,oFAFM,QAAQ,OAAO,CAAC,CA4B5B;AAUM,qHAwBN"}
1
+ {"version":3,"file":"async.d.ts","sourceRoot":"","sources":["../../src/async.ts"],"names":[],"mappings":"AAMA;;GAEG;AACH,eAAO,MAAM,KAAK,OAAQ,MAAM,kBAc9B,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,cAAc,0CAA2C,MAAM,SAAS,KAAK,eAmBzF,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,WAAY,QAAQ,sDAwBhD,CAAC"}
package/dist/src/async.js CHANGED
@@ -3,18 +3,13 @@
3
3
  // Copyright 2020 DXOS.org
4
4
  //
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.waitForCondition = exports.promiseTimeout = exports.timeout = exports.sleep = exports.noop = void 0;
6
+ exports.waitForCondition = exports.promiseTimeout = exports.sleep = void 0;
7
7
  const trigger_1 = require("./trigger");
8
- // TODO(burdon): Remove.
9
- const noop = (...args) => args;
10
- exports.noop = noop;
11
8
  /**
12
- * Timesout after delay.
13
- * @param timeout
14
- * @returns {Promise<unknown>}
9
+ * Times out after delay.
15
10
  */
16
- const sleep = timeout => new Promise((resolve) => {
17
- const finish = Date.now() + timeout;
11
+ const sleep = (ms) => new Promise((resolve) => {
12
+ const finish = Date.now() + ms;
18
13
  // `setTimeout` does not guarantee execution at >= the scheduled time and may execute slightly early.
19
14
  const sleeper = () => {
20
15
  const delta = finish - Date.now();
@@ -29,63 +24,31 @@ const sleep = timeout => new Promise((resolve) => {
29
24
  });
30
25
  exports.sleep = sleep;
31
26
  /**
32
- * Async timeout
33
- * @param f
34
- * @param [timeout]
35
- * @returns {Promise<unknown>}
36
- */
37
- const timeout = (f, timeout = 0) => new Promise((resolve, reject) => {
38
- const handle = setTimeout(async () => {
39
- try {
40
- const value = await f();
41
- resolve(value);
42
- }
43
- catch (err) {
44
- reject(err);
45
- }
46
- finally {
47
- clearTimeout(handle);
48
- }
49
- }, timeout);
50
- });
51
- exports.timeout = timeout;
52
- /**
53
- * @param {Promise} promise
54
- * @param {Number} timeout
55
- * @returns {Promise<unknown>}
27
+ * @param [timeout] How long to wait, in milliseconds (0 = no timeout).
56
28
  */
57
29
  const promiseTimeout = (promise, timeout, error) => {
58
30
  let cancelTimeout;
59
31
  const timeoutPromise = new Promise((resolve, reject) => {
60
32
  const timer = setTimeout(() => {
61
- reject(error || new Error(`Timed out in ${timeout} ms.`));
33
+ reject(error);
62
34
  }, timeout);
63
35
  cancelTimeout = () => {
64
36
  clearTimeout(timer);
65
- resolve();
66
37
  };
67
38
  });
68
- return new Promise((resolve, reject) => {
69
- Promise.race([
70
- promise,
71
- timeoutPromise
72
- ]).then((...result) => {
73
- cancelTimeout();
74
- resolve(...result);
75
- }, (err) => {
76
- cancelTimeout();
77
- reject(err);
78
- });
39
+ return Promise.race([
40
+ promise,
41
+ timeoutPromise
42
+ ]).finally(() => {
43
+ cancelTimeout();
79
44
  });
80
45
  };
81
46
  exports.promiseTimeout = promiseTimeout;
82
47
  /**
83
48
  * Returns a Promise which resolves when `condFn` returns truthy. The value returned by
84
49
  * `condFn` is used to resolve the Promise.
85
- * @param {function} condFn
86
- * @param {number} [timeout] How long to wait, in milliseconds (0 = no timeout).
87
- * @param {number} [interval=10] How frequently to check, in milliseconds.
88
- * @returns {*}
50
+ * @param [timeout] How long to wait, in milliseconds (0 = no timeout).
51
+ * @param [interval=10] How frequently to check, in milliseconds.
89
52
  */
90
53
  const waitForCondition = (condFn, timeout = 0, interval = 10) => {
91
54
  const stopTime = timeout ? Date.now() + timeout : 0;
@@ -109,7 +72,7 @@ const waitForCondition = (condFn, timeout = 0, interval = 10) => {
109
72
  }
110
73
  };
111
74
  setTimeout(waiter, 0);
112
- return timeout ? (0, exports.promiseTimeout)(provider(), timeout) : provider();
75
+ return timeout ? (0, exports.promiseTimeout)(provider(), timeout, new Error('Timeout')) : provider();
113
76
  };
114
77
  exports.waitForCondition = waitForCondition;
115
78
  //# sourceMappingURL=async.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"async.js","sourceRoot":"","sources":["../../src/async.js"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;;AAEF,uCAAoC;AAEpC,wBAAwB;AACjB,MAAM,IAAI,GAAG,CAAC,GAAG,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC;AAAzB,QAAA,IAAI,QAAqB;AAEtC;;;;GAIG;AACI,MAAM,KAAK,GAAG,OA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AQ,EAAE,EAAE,OAAO,EAAE,IAAI,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC;AAC1F,CAAC,CAAC;AAxBW,QAAA,gBAAgB,oBAwB3B"}
@@ -1 +1 @@
1
- {"version":3,"file":"async.test.d.ts","sourceRoot":"","sources":["../../src/async.test.js"],"names":[],"mappings":""}
1
+ {"version":3,"file":"async.test.d.ts","sourceRoot":"","sources":["../../src/async.test.ts"],"names":[],"mappings":""}
@@ -7,6 +7,20 @@ Object.defineProperty(exports, "__esModule", { value: true });
7
7
  const debug_1 = require("@dxos/debug");
8
8
  const async_1 = require("./async");
9
9
  const trigger_1 = require("./trigger");
10
+ const timeout = (f, timeout = 0) => new Promise((resolve, reject) => {
11
+ const handle = setTimeout(async () => {
12
+ try {
13
+ const value = await f();
14
+ resolve(value);
15
+ }
16
+ catch (err) {
17
+ reject(err);
18
+ }
19
+ finally {
20
+ clearTimeout(handle);
21
+ }
22
+ }, timeout);
23
+ });
10
24
  test('sleep', async () => {
11
25
  const now = Date.now();
12
26
  await (0, async_1.sleep)(100);
@@ -21,13 +35,13 @@ test('trigger', async () => {
21
35
  });
22
36
  test('promiseTimeout', async () => {
23
37
  {
24
- const promise = (0, async_1.timeout)(() => 'test', 100);
25
- const value = await (0, async_1.promiseTimeout)(promise, 200);
38
+ const promise = timeout(() => 'test', 100);
39
+ const value = await (0, async_1.promiseTimeout)(promise, 200, new Error('timeout'));
26
40
  expect(value).toBe('test');
27
41
  }
28
42
  {
29
- const promise = (0, async_1.timeout)(() => 'test', 200);
30
- await (0, debug_1.expectToThrow)(() => (0, async_1.promiseTimeout)(promise, 100));
43
+ const promise = timeout(() => 'test', 200);
44
+ await (0, debug_1.expectToThrow)(() => (0, async_1.promiseTimeout)(promise, 100, new Error('timeout')));
31
45
  }
32
46
  });
33
47
  test('waitForCondition', async () => {
@@ -1 +1 @@
1
- {"version":3,"file":"async.test.js","sourceRoot":"","sources":["../../src/async.test.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AE,GAAG,CAAC,CAAC;QAC3C,MAAM,IAAA,qBAAa,EAAC,GAAG,EAAE,CAAC,IAAA,sBAAc,EAAC,OAAO,EAAE,GAAG,EAAE,IAAI,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;KAC/E;AACH,CAAC,CAAC,CAAC;AAEH,IAAI,CAAC,kBAAkB,EAAE,KAAK,IAAI,EAAE;IAClC;QACE,MAAM,IAAI,GAAG,IAAI,CAAC,GAAG,EAAE,GAAG,GAAG,CAAC;QAC9B,MAAM,KAAK,GAAG,MAAM,IAAA,wBAAgB,EAAC,GAAG,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,IAAI,EAAE,GAAG,CAAC,CAAC;QACnE,MAAM,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACzB,MAAM,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,sBAAsB,CAAC,IAAI,CAAC,CAAC;KACjD;IAED;QACE,MAAM,IAAI,GAAG,IAAI,CAAC,GAAG,EAAE,GAAG,GAAG,CAAC;QAC9B,MAAM,IAAA,qBAAa,EAAC,GAAG,EAAE,CAAC,IAAA,wBAAgB,EAAC,GAAG,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,IAAI,EAAE,GAAG,CAAC,CAAC,CAAC;KAC3E;AACH,CAAC,CAAC,CAAC"}
@@ -44,7 +44,7 @@ const waitForEvent = (eventEmitter, eventName, test, timeout, error) => {
44
44
  }
45
45
  });
46
46
  });
47
- return timeout ? (0, async_1.promiseTimeout)(promise, timeout, error).finally(off) : promise.finally(off);
47
+ return timeout ? (0, async_1.promiseTimeout)(promise, timeout, error !== null && error !== void 0 ? error : new Error()).finally(off) : promise.finally(off);
48
48
  };
49
49
  exports.waitForEvent = waitForEvent;
50
50
  //# sourceMappingURL=events.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"events.js","sourceRoot":"","sources":["../../src/events.js"],"names":[],"mappings":";AAAA,EAA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AAC,CAAC,CAAC;IAEH,OAAO,OAAO,CAAC,CAAC,CAAC,IAAA,sBAAc,EAAC,OAAO,EAAE,OAAO,EAAE,KAAK,aAAL,KAAK,cAAL,KAAK,GAAI,IAAI,KAAK,EAAE,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;AAC9G,CAAC,CAAC;AAZW,QAAA,YAAY,gBAYvB"}
@@ -1 +1 @@
1
- {"program":{"fileNames":["../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es5.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2016.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.esnext.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.array.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.object.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.string.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.string.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.promise.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.string.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.weakref.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.intl.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.esnext.intl.d.ts","../src/trigger.ts","../src/async.js","../../debug/dist/src/assert.d.ts","../../debug/dist/src/console.d.ts","../../debug/dist/src/error-handler.d.ts","../../debug/dist/src/error-stream.d.ts","../../debug/dist/src/errors/dxos-error.d.ts","../../debug/dist/src/errors/errors.d.ts","../../debug/dist/src/errors/index.d.ts","../../debug/dist/src/fail.d.ts","../../debug/dist/src/log-method.d.ts","../../debug/dist/src/logging.d.ts","../../debug/dist/src/raise.d.ts","../../debug/dist/src/stack-trace.d.ts","../../debug/dist/src/strings.d.ts","../../debug/dist/src/throw.d.ts","../../debug/dist/src/throw-unhandled-rejection.d.ts","../../debug/dist/src/timeout-warning.d.ts","../../debug/dist/src/index.d.ts","../src/async.test.js","../src/callback.ts","../src/event.ts","../src/event.test.ts","../src/events.js","../src/latch.ts","../src/events.test.js","../src/lock.ts","../src/sink.ts","../src/types.ts","../src/index.ts","../src/lock.test.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/cleanupSemantic.d.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/types.d.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/diffLines.d.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/printDiffs.d.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/index.d.ts","../../../../common/temp/node_modules/.pnpm/pretty-format@26.6.2/node_modules/pretty-format/build/types.d.ts","../../../../common/temp/node_modules/.pnpm/pretty-format@26.6.2/node_modules/pretty-format/build/index.d.ts","../../../../common/temp/node_modules/.pnpm/@types+jest@26.0.24/node_modules/@types/jest/index.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/assert.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/globals.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/async_hooks.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/buffer.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/child_process.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/cluster.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/console.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/constants.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/crypto.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/dgram.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/dns.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/domain.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/events.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/fs.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/fs/promises.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/http.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/http2.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/https.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/inspector.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/module.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/net.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/os.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/path.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/perf_hooks.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/process.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/punycode.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/querystring.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/readline.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/repl.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/stream.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/string_decoder.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/timers.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/tls.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/trace_events.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/tty.d.ts","../../../../common/temp/node_modules/.pnpm/querystring@0.2.1/node_modules/querystring/decode.d.ts","../../../../common/temp/node_modules/.pnpm/querystring@0.2.1/node_modules/querystring/encode.d.ts","../../../../common/temp/node_modules/.pnpm/querystring@0.2.1/node_modules/querystring/index.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/url.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/util.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/v8.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/vm.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/wasi.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/worker_threads.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/zlib.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/globals.global.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/index.d.ts"],"fileInfos":[{"version":"89f78430e422a0f06d13019d60d5a45b37ec2d28e67eb647f73b1b0d19a46b72","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","e6b724280c694a9f588847f754198fb96c43d805f065c3a5b28bbc9594541c84","e21c071ca3e1b4a815d5f04a7475adcaeea5d64367e840dd0154096d705c3940","746d62152361558ea6d6115cf0da4dd10ede041d14882ede3568bce5dc4b4f1f","2cc028cd0bdb35b1b5eb723d84666a255933fffbea607f72cbd0c7c7b4bee144",{"version":"d8996609230d17e90484a2dd58f22668f9a05a3bfe00bfb1d6271171e54a31fb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"4378fc8122ec9d1a685b01eb66c46f62aba6b239ca7228bb6483bcf8259ee493","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"1b3fe904465430e030c93239a348f05e1be80640d91f2f004c3512c2c2c89f34","affectsGlobalScope":true},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"d071129cba6a5f2700be09c86c07ad2791ab67d4e5ed1eb301d6746c62745ea4","affectsGlobalScope":true},{"version":"6c55633c733c8378db65ac3da7a767c3cf2cf3057f0565a9124a16a3a2019e87","affectsGlobalScope":true},{"version":"fb4416144c1bf0323ccbc9afb0ab289c07312214e8820ad17d709498c865a3fe","affectsGlobalScope":true},{"version":"5b0ca94ec819d68d33da516306c15297acec88efeb0ae9e2b39f71dbd9685ef7","affectsGlobalScope":true},{"version":"e8c9f4e445a489991ca1a4232667de3ac36b07ba75ea335971fbeacf2d26fe67","affectsGlobalScope":true},{"version":"10bbdc1981b8d9310ee75bfac28ee0477bb2353e8529da8cff7cb26c409cb5e8","affectsGlobalScope":true},"32cef65cbe89bdb4a04b04e3b4f113338d9e70b56c9c2cdb909ebd4091673acf","cc3f7b98cb4a477c4dcb9bbdebb1593317143394ce384c3f35172765e6be9fbb","e881c10a9375e1e7999f529d6a7e0f57fda7280fb232fb927c221df6546a9c86","49dada859a1e7a2ccfc38c4ee75ef4915983f033a751d0433c80b3932e4f75bc","408961bf1c33d835d9aa7f67892daf49830db17b892eab53a60b70a340e9a37a","217767768c03d9107fab244f0a1d41ee2fc9beea572b9b10d3bbfcda258fa471","4f1f99c145ff1ff5408e1cf043a4b47491e94fc1995d4db7915a5c5a46345d5f","809122f9b60f8459313728dad366f627d7163015cbad50af9dc60551f84f50e5","307608ba5cb4170e819ebda0ce4f2d18f102abead268a4bbcb42af67f876693a","a52dffe094fa29673bc950ed469299c1852d8cfcfa4d6cfb8a5b7d6e0ca55c3c","391b4ea9ef9bb44bb409b71f3f412cdced854a0851e903131a08b8aba4538109","f145064a05f34fcff1d3fd35a69249b90dbb393eb3c746da839d156f1ab2cd69","9e5f9b01148b742d5e7498fea6e98a177f5e4e3d796fc2a371fdded6e560fce8","0626cdb0f8eab865903c9f639e0ca3b2625baa11702720ffd7f92d270274dd39","03e17e31764c291d6c33e7bc77006b844db6c1eff8269479df60fa938b5a0651","58a2ca0c379c5761fd1cd6e1645cdab0325f5cf0a04cd43d5f551bb727750dcf","b7760db3c4335e90855d654892bdad4ab5c6741538a766ec3a9db8ad8c69d7ac","918542c297b47033b2e4691fdfd9d8ef7029ac618089bc8141fd76c9e1eead7d","a9e293e60119009fe3098c83242507708f3b1fea7b1572b4c5560293877d3d9e","818ee84ab963ca0dd91f28217a5f942ca4fa3e9966af50f1f82e9c14df83adbe","b5a236318130da6276bd5e917a7516541e67e11f2d8415698ad7acd968900441","c4089f7d8a81eb30f7b53b01b58674b4570d6ab1208ad73c1684fdd589388efa","7b82390d03d800eb1d74ba98ff7e9ca9f3205a8e52b5b695814e235b52690bf3","b1649834f040ee782e6efd240a08b36bb30098f1fadf908cfef31d7cbd74d867","5aab60228dd1f9e1eeec271f928fa05219894afe8552946a52bf536e12273cce","67d33a07f619a2a5253bba755f12954cd208bbd3015f48138dad8d8b5d9834c0","28cf9caeaf444de46bf20905dc58d5fc32ccbcd21bbe16ef3b1212d8ffd0d103","4f48888e4492f371eb7d975a74b060f781d10de8b2e578ec89409bb20a39d9a2","46dbc4e8177e2d509c51b4f63779207d146da3b51a32e3391b0923366207eb35","1d802bded9c759da01fdb14a67f2b6ce856f30c149b4a43a48e43f44de5ac800","9cf95399adc7b8b07160419a81617a79ae67f03cc8ff3a7b979996dc5dafa64d","d8aab31ba8e618cc3eea10b0945de81cb93b7e8150a013a482332263b9305322","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","561eca7a381b96d6ccac6e4061e6d2ae53f5bc44203f3fd9f5b26864c32ae6e9","62ea38627e3ebab429f7616812a9394d327c2bc271003dfba985de9b4137369f","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"516a426e3960379f310107635b8f3a7e8c307c6c665080b128039d9299ec4087","affectsGlobalScope":true},"4c2c4f53e8eedd970f8afa369d7371544fb6231bf95e659f8602e09abe74d5a5",{"version":"dc5f6951bbf5b544349cbdef895c08dee6929818abd27d7d53c38cf1209091b3","affectsGlobalScope":true},"64e2803203b14d7f104f570f2152fde13abb6edc17b2ddb33d81ad86cf43d494","2c8d9e3331aec52d9a6d4040352c00282c3abaf48053ed0944528a4845c9caa3","9b2a8f604e7c0482a9061755f00b287cc99bd8718dc82d8207dd74c599b6dc43","d0fc76a91c828fbe3f0be5d683273634b7b101068333ceed975a8a9ac464137b",{"version":"1a048ff164b8d9609f5de3139d4e37f6e8a82af82087ac414b9208f52ef8aac7","affectsGlobalScope":true},"3111079f3cb5f2b9c812ca3f46161562bce5bfb355e915f46ed46c41714dc1c3","64576aba4ff801004122056ccd049f0597aa471dcfd7670a6a0b877ee8dd97c0","b32b6b16cb0bda68199582ad6f22242d07ee75fac9b1f28a98cd838afc5eea45","4441ee4119824bfaebc49308559edd7545978f9cb41a40f115074e1031dde75f",{"version":"60693a88462d0e97900123b5bf7c73e146ce0cc94da46a61fe6775b430d2ff05","affectsGlobalScope":true},{"version":"588c69eda58b9202676ec7ca11a72c3762819b46a0ed72462c769846153c447c","affectsGlobalScope":true},"cc829932ffaf5c49092f878bec18af1fa5d8591b45a45e2b7f757f793cb3b4ed","47db10fdc4e76c4f4598cf7c91ba6bfde6cf6d8082c51860fe751643bf359739","05d7d95e24bc2897bf20ce041c3dc3cca814e07148a93999145b1a0ad491094c","d1080e49778c0b2ce656042ebfa43f89dffb96ac00f86a34762188a21857ffd4","0ce99c641ea20b0c0c09d093fc28f18f5ab31dc80033707a1ac3154399de2559","f0c33a0b325d3499cc9aded7d32886f998c9a27b465097c6cc136944d0aafdaa","44e42ed6ec9c4451ebe89524e80ac8564e9dd0988c56e6c58f393c810730595d","03c91e8833eef54dc44db99d7deb469b5e3cec82f23054b4286a2380e0e00996","1606ea615c0a5ea9f5c1376a33e34c0e1112e8dee31a5b3b8a74ce781893aa6f","9fef9de633d01cb7f01f68195626a890ededd25cf96a1e785617d08c8668230d","4455c78d226d061b1203c7614c6c6eb5f4f9db5f00d44ff47d0112de8766fbc4",{"version":"bf89ceb26132596b859cd4d129ce3f447134b444dec87966ba65cd7e8e9e0cb0","affectsGlobalScope":true},"4465a636f5f6e9665a90e30691862c9e0a3ac2edc0e66296704f10865e924f2a","9af781f03d44f5635ed7844be0ce370d9d595d4b4ec67cad88f0fac03255257e","f9fd4c3ef6de27fa0e256f4e75b61711c4be05a3399f7714621d3edc832e36b0","e49290b7a927995c0d7e6b2b9c8296284b68a9036d9966531de65185269258d7","a11d4ba43bf0825d7285d54dec6cb951685cd458a4de3c5c1800f7cbf7799009","874ca809b79276460011480a2829f4c8d4db29416dd411f71efbf8f497f0ac09","82e1723b20fa0b15a7da0d1a03fec88348f82f640f7a2f308d6c0fac780cfc7c","e0202c3e09775b86b902f21623e55896cea98750efbdf0691ca7473af06fe551","23a28f834a078986bbf58f4e3705956983ff81c3c2493f3db3e5f0e8a9507779","4febdf7f3ec92706c58e0b4e8159cd6de718284ef384260b07c9641c13fc70ce","ad7e61eca7f2f8bf47e72695f9f6663b75e41d87ef49abdb17c0cb843862f8aa","ecba2e44af95b0599c269a92628cec22e752868bce37396740deb51a5c547a26","46a9fb41a8f3bc7539eeebc15a6e04b9e55d7537a081615ad3614220d34c3e0f","a2666b43d889b4882ac6ede1c48128bac351886854e94f832b20d3730e5062c5","7335933d9f30dcfd2c4b6080a8b78e81912a7fcefb1dafccb67ca4cb4b3ac23d","a6bfe9de9adef749010c118104b071d14943802ff0614732b47ce4f1c3e383cd","4c3d0e10396646db4a1e917fb852077ee77ae62e512913bef9cccc2bb0f8bd0e","3b220849d58140dcc6718f5b52dcd29fdb79c45bc28f561cbd29eb1cac6cce13","0ee22fce41f7417a24c808d266e91b850629113c104713a35854393d55994beb","22d1b1d965baba05766613e2e6c753bb005d4386c448cafd72c309ba689e8c24",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"2a7d39ea70e483d3ebcde44031b6552940f295349bee8d486e8bdf6380162302"],"options":{"composite":true,"declarationMap":true,"esModuleInterop":true,"experimentalDecorators":true,"jsx":2,"module":1,"noImplicitOverride":true,"outDir":"./","skipLibCheck":true,"sourceMap":true,"strict":true,"stripInternal":true,"target":5},"fileIdsList":[[80,82],[84],[86],[87],[88,96,97,104,113],[88,89,96,104],[90,123],[91,92,97,105],[92,113],[93,94,96,104],[94],[95,96],[96],[96,97,98,113,122],[97,98],[99,104,113,122],[96,97,99,100,104,113,116,122],[99,101,113,116,122],[84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,122,123,124,125,126,127,128,129],[96,102],[103,122],[94,96,104,113],[105],[106],[86,107],[108,118],[109],[110],[96,111],[111,112,123,125],[96,113],[114],[115],[104,116],[117],[104,118],[110,122],[123],[113,124],[125],[126],[96,98,113,122,125,127],[113,128],[76,77],[76,77,78,79],[81],[119,120],[45],[45,46,63],[46,66],[63],[46],[46,63,68,69,96],[45,46,65,66,68,69,71,72,73],[46,71],[45,96],[51],[51,52],[47,48,49,50,53,54,55,56,57,58,59,60,61,62]],"referencedMap":[[83,1],[84,2],[86,3],[87,4],[88,5],[89,6],[90,7],[91,8],[92,9],[93,10],[94,11],[95,12],[96,13],[97,14],[98,15],[99,16],[100,17],[101,18],[130,19],[102,20],[103,21],[104,22],[105,23],[106,24],[107,25],[108,26],[109,27],[110,28],[111,29],[112,30],[113,31],[114,32],[115,33],[116,34],[117,35],[118,36],[122,37],[123,38],[124,39],[125,40],[126,41],[127,42],[128,43],[78,44],[80,45],[79,44],[82,46],[121,47],[46,48],[64,49],[67,50],[66,51],[68,52],[70,53],[74,54],[69,2],[75,55],[71,48],[72,56],[49,13],[52,57],[53,58],[63,59]],"exportedModulesMap":[[83,1],[84,2],[86,3],[87,4],[88,5],[89,6],[90,7],[91,8],[92,9],[93,10],[94,11],[95,12],[96,13],[97,14],[98,15],[99,16],[100,17],[101,18],[130,19],[102,20],[103,21],[104,22],[105,23],[106,24],[107,25],[108,26],[109,27],[110,28],[111,29],[112,30],[113,31],[114,32],[115,33],[116,34],[117,35],[118,36],[122,37],[123,38],[124,39],[125,40],[126,41],[127,42],[128,43],[78,44],[80,45],[79,44],[82,46],[121,47],[46,48],[64,49],[67,50],[66,51],[68,52],[70,53],[74,54],[69,2],[75,55],[71,48],[72,56],[49,13],[52,57],[53,58],[63,59]],"semanticDiagnosticsPerFile":[83,84,86,87,88,89,90,91,92,93,94,95,96,97,98,85,129,99,100,101,130,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,122,123,124,125,126,127,128,76,78,80,79,77,82,81,119,120,121,11,10,2,12,13,14,15,16,17,18,19,3,4,23,20,21,22,24,25,26,5,27,28,29,30,6,31,32,33,34,7,39,35,36,37,38,8,43,40,41,42,1,9,44,46,64,65,67,66,68,70,74,69,75,71,72,45,73,47,48,49,50,51,52,53,54,63,55,56,57,58,59,61,60,62]},"version":"4.5.3"}
1
+ {"program":{"fileNames":["../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es5.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2016.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.esnext.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.array.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.object.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.string.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.string.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.promise.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.string.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.weakref.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.es2021.intl.d.ts","../../../../common/temp/node_modules/.pnpm/typescript@4.5.3/node_modules/typescript/lib/lib.esnext.intl.d.ts","../../debug/dist/src/assert.d.ts","../../debug/dist/src/console.d.ts","../../debug/dist/src/error-handler.d.ts","../../debug/dist/src/error-stream.d.ts","../../debug/dist/src/errors/dxos-error.d.ts","../../debug/dist/src/errors/errors.d.ts","../../debug/dist/src/errors/index.d.ts","../../debug/dist/src/fail.d.ts","../../debug/dist/src/log-method.d.ts","../../debug/dist/src/logging.d.ts","../../debug/dist/src/raise.d.ts","../../debug/dist/src/stack-trace.d.ts","../../debug/dist/src/strings.d.ts","../../debug/dist/src/throw.d.ts","../../debug/dist/src/throw-unhandled-rejection.d.ts","../../debug/dist/src/timeout-warning.d.ts","../../debug/dist/src/index.d.ts","../src/trigger.ts","../src/async.ts","../src/async.test.ts","../src/callback.ts","../src/event.ts","../src/event.test.ts","../src/events.js","../src/latch.ts","../src/events.test.js","../src/lock.ts","../src/sink.ts","../src/types.ts","../src/index.ts","../src/lock.test.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/cleanupSemantic.d.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/types.d.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/diffLines.d.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/printDiffs.d.ts","../../../../common/temp/node_modules/.pnpm/jest-diff@26.6.2/node_modules/jest-diff/build/index.d.ts","../../../../common/temp/node_modules/.pnpm/pretty-format@26.6.2/node_modules/pretty-format/build/types.d.ts","../../../../common/temp/node_modules/.pnpm/pretty-format@26.6.2/node_modules/pretty-format/build/index.d.ts","../../../../common/temp/node_modules/.pnpm/@types+jest@26.0.24/node_modules/@types/jest/index.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/assert.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/globals.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/async_hooks.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/buffer.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/child_process.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/cluster.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/console.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/constants.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/crypto.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/dgram.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/dns.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/domain.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/events.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/fs.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/fs/promises.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/http.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/http2.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/https.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/inspector.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/module.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/net.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/os.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/path.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/perf_hooks.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/process.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/punycode.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/querystring.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/readline.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/repl.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/stream.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/string_decoder.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/timers.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/tls.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/trace_events.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/tty.d.ts","../../../../common/temp/node_modules/.pnpm/querystring@0.2.1/node_modules/querystring/decode.d.ts","../../../../common/temp/node_modules/.pnpm/querystring@0.2.1/node_modules/querystring/encode.d.ts","../../../../common/temp/node_modules/.pnpm/querystring@0.2.1/node_modules/querystring/index.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/url.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/util.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/v8.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/vm.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/wasi.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/worker_threads.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/zlib.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/globals.global.d.ts","../../../../common/temp/node_modules/.pnpm/@types+node@14.18.0/node_modules/@types/node/index.d.ts"],"fileInfos":[{"version":"89f78430e422a0f06d13019d60d5a45b37ec2d28e67eb647f73b1b0d19a46b72","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","e6b724280c694a9f588847f754198fb96c43d805f065c3a5b28bbc9594541c84","e21c071ca3e1b4a815d5f04a7475adcaeea5d64367e840dd0154096d705c3940","746d62152361558ea6d6115cf0da4dd10ede041d14882ede3568bce5dc4b4f1f","2cc028cd0bdb35b1b5eb723d84666a255933fffbea607f72cbd0c7c7b4bee144",{"version":"d8996609230d17e90484a2dd58f22668f9a05a3bfe00bfb1d6271171e54a31fb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"4378fc8122ec9d1a685b01eb66c46f62aba6b239ca7228bb6483bcf8259ee493","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"1b3fe904465430e030c93239a348f05e1be80640d91f2f004c3512c2c2c89f34","affectsGlobalScope":true},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"d071129cba6a5f2700be09c86c07ad2791ab67d4e5ed1eb301d6746c62745ea4","affectsGlobalScope":true},{"version":"6c55633c733c8378db65ac3da7a767c3cf2cf3057f0565a9124a16a3a2019e87","affectsGlobalScope":true},{"version":"fb4416144c1bf0323ccbc9afb0ab289c07312214e8820ad17d709498c865a3fe","affectsGlobalScope":true},{"version":"5b0ca94ec819d68d33da516306c15297acec88efeb0ae9e2b39f71dbd9685ef7","affectsGlobalScope":true},{"version":"e8c9f4e445a489991ca1a4232667de3ac36b07ba75ea335971fbeacf2d26fe67","affectsGlobalScope":true},{"version":"10bbdc1981b8d9310ee75bfac28ee0477bb2353e8529da8cff7cb26c409cb5e8","affectsGlobalScope":true},"e881c10a9375e1e7999f529d6a7e0f57fda7280fb232fb927c221df6546a9c86","49dada859a1e7a2ccfc38c4ee75ef4915983f033a751d0433c80b3932e4f75bc","408961bf1c33d835d9aa7f67892daf49830db17b892eab53a60b70a340e9a37a","217767768c03d9107fab244f0a1d41ee2fc9beea572b9b10d3bbfcda258fa471","4f1f99c145ff1ff5408e1cf043a4b47491e94fc1995d4db7915a5c5a46345d5f","809122f9b60f8459313728dad366f627d7163015cbad50af9dc60551f84f50e5","307608ba5cb4170e819ebda0ce4f2d18f102abead268a4bbcb42af67f876693a","a52dffe094fa29673bc950ed469299c1852d8cfcfa4d6cfb8a5b7d6e0ca55c3c","391b4ea9ef9bb44bb409b71f3f412cdced854a0851e903131a08b8aba4538109","f145064a05f34fcff1d3fd35a69249b90dbb393eb3c746da839d156f1ab2cd69","9e5f9b01148b742d5e7498fea6e98a177f5e4e3d796fc2a371fdded6e560fce8","0626cdb0f8eab865903c9f639e0ca3b2625baa11702720ffd7f92d270274dd39","03e17e31764c291d6c33e7bc77006b844db6c1eff8269479df60fa938b5a0651","58a2ca0c379c5761fd1cd6e1645cdab0325f5cf0a04cd43d5f551bb727750dcf","b7760db3c4335e90855d654892bdad4ab5c6741538a766ec3a9db8ad8c69d7ac","918542c297b47033b2e4691fdfd9d8ef7029ac618089bc8141fd76c9e1eead7d","a9e293e60119009fe3098c83242507708f3b1fea7b1572b4c5560293877d3d9e","32cef65cbe89bdb4a04b04e3b4f113338d9e70b56c9c2cdb909ebd4091673acf","e73df9a93e884d992a1d95a877d5ca4672bfc2e01d76498db39aff4367ff7ad2","6b87ee5a46364b2ae907e03f47a9c327a19c87547f50391512a1a81fe1ef6be7","b5a236318130da6276bd5e917a7516541e67e11f2d8415698ad7acd968900441","c4089f7d8a81eb30f7b53b01b58674b4570d6ab1208ad73c1684fdd589388efa","7b82390d03d800eb1d74ba98ff7e9ca9f3205a8e52b5b695814e235b52690bf3","6a884f1f2bca5e25057d7175e566f9166be08ae34a6b5a75260f0a00e4c0deba","5aab60228dd1f9e1eeec271f928fa05219894afe8552946a52bf536e12273cce","67d33a07f619a2a5253bba755f12954cd208bbd3015f48138dad8d8b5d9834c0","28cf9caeaf444de46bf20905dc58d5fc32ccbcd21bbe16ef3b1212d8ffd0d103","4f48888e4492f371eb7d975a74b060f781d10de8b2e578ec89409bb20a39d9a2","46dbc4e8177e2d509c51b4f63779207d146da3b51a32e3391b0923366207eb35","1d802bded9c759da01fdb14a67f2b6ce856f30c149b4a43a48e43f44de5ac800","9cf95399adc7b8b07160419a81617a79ae67f03cc8ff3a7b979996dc5dafa64d","d8aab31ba8e618cc3eea10b0945de81cb93b7e8150a013a482332263b9305322","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","561eca7a381b96d6ccac6e4061e6d2ae53f5bc44203f3fd9f5b26864c32ae6e9","62ea38627e3ebab429f7616812a9394d327c2bc271003dfba985de9b4137369f","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"516a426e3960379f310107635b8f3a7e8c307c6c665080b128039d9299ec4087","affectsGlobalScope":true},"4c2c4f53e8eedd970f8afa369d7371544fb6231bf95e659f8602e09abe74d5a5",{"version":"dc5f6951bbf5b544349cbdef895c08dee6929818abd27d7d53c38cf1209091b3","affectsGlobalScope":true},"64e2803203b14d7f104f570f2152fde13abb6edc17b2ddb33d81ad86cf43d494","2c8d9e3331aec52d9a6d4040352c00282c3abaf48053ed0944528a4845c9caa3","9b2a8f604e7c0482a9061755f00b287cc99bd8718dc82d8207dd74c599b6dc43","d0fc76a91c828fbe3f0be5d683273634b7b101068333ceed975a8a9ac464137b",{"version":"1a048ff164b8d9609f5de3139d4e37f6e8a82af82087ac414b9208f52ef8aac7","affectsGlobalScope":true},"3111079f3cb5f2b9c812ca3f46161562bce5bfb355e915f46ed46c41714dc1c3","64576aba4ff801004122056ccd049f0597aa471dcfd7670a6a0b877ee8dd97c0","b32b6b16cb0bda68199582ad6f22242d07ee75fac9b1f28a98cd838afc5eea45","4441ee4119824bfaebc49308559edd7545978f9cb41a40f115074e1031dde75f",{"version":"60693a88462d0e97900123b5bf7c73e146ce0cc94da46a61fe6775b430d2ff05","affectsGlobalScope":true},{"version":"588c69eda58b9202676ec7ca11a72c3762819b46a0ed72462c769846153c447c","affectsGlobalScope":true},"cc829932ffaf5c49092f878bec18af1fa5d8591b45a45e2b7f757f793cb3b4ed","47db10fdc4e76c4f4598cf7c91ba6bfde6cf6d8082c51860fe751643bf359739","05d7d95e24bc2897bf20ce041c3dc3cca814e07148a93999145b1a0ad491094c","d1080e49778c0b2ce656042ebfa43f89dffb96ac00f86a34762188a21857ffd4","0ce99c641ea20b0c0c09d093fc28f18f5ab31dc80033707a1ac3154399de2559","f0c33a0b325d3499cc9aded7d32886f998c9a27b465097c6cc136944d0aafdaa","44e42ed6ec9c4451ebe89524e80ac8564e9dd0988c56e6c58f393c810730595d","03c91e8833eef54dc44db99d7deb469b5e3cec82f23054b4286a2380e0e00996","1606ea615c0a5ea9f5c1376a33e34c0e1112e8dee31a5b3b8a74ce781893aa6f","9fef9de633d01cb7f01f68195626a890ededd25cf96a1e785617d08c8668230d","4455c78d226d061b1203c7614c6c6eb5f4f9db5f00d44ff47d0112de8766fbc4",{"version":"bf89ceb26132596b859cd4d129ce3f447134b444dec87966ba65cd7e8e9e0cb0","affectsGlobalScope":true},"4465a636f5f6e9665a90e30691862c9e0a3ac2edc0e66296704f10865e924f2a","9af781f03d44f5635ed7844be0ce370d9d595d4b4ec67cad88f0fac03255257e","f9fd4c3ef6de27fa0e256f4e75b61711c4be05a3399f7714621d3edc832e36b0","e49290b7a927995c0d7e6b2b9c8296284b68a9036d9966531de65185269258d7","a11d4ba43bf0825d7285d54dec6cb951685cd458a4de3c5c1800f7cbf7799009","874ca809b79276460011480a2829f4c8d4db29416dd411f71efbf8f497f0ac09","82e1723b20fa0b15a7da0d1a03fec88348f82f640f7a2f308d6c0fac780cfc7c","e0202c3e09775b86b902f21623e55896cea98750efbdf0691ca7473af06fe551","23a28f834a078986bbf58f4e3705956983ff81c3c2493f3db3e5f0e8a9507779","4febdf7f3ec92706c58e0b4e8159cd6de718284ef384260b07c9641c13fc70ce","ad7e61eca7f2f8bf47e72695f9f6663b75e41d87ef49abdb17c0cb843862f8aa","ecba2e44af95b0599c269a92628cec22e752868bce37396740deb51a5c547a26","46a9fb41a8f3bc7539eeebc15a6e04b9e55d7537a081615ad3614220d34c3e0f","a2666b43d889b4882ac6ede1c48128bac351886854e94f832b20d3730e5062c5","7335933d9f30dcfd2c4b6080a8b78e81912a7fcefb1dafccb67ca4cb4b3ac23d","a6bfe9de9adef749010c118104b071d14943802ff0614732b47ce4f1c3e383cd","4c3d0e10396646db4a1e917fb852077ee77ae62e512913bef9cccc2bb0f8bd0e","3b220849d58140dcc6718f5b52dcd29fdb79c45bc28f561cbd29eb1cac6cce13","0ee22fce41f7417a24c808d266e91b850629113c104713a35854393d55994beb","22d1b1d965baba05766613e2e6c753bb005d4386c448cafd72c309ba689e8c24",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"2a7d39ea70e483d3ebcde44031b6552940f295349bee8d486e8bdf6380162302"],"options":{"composite":true,"declarationMap":true,"esModuleInterop":true,"experimentalDecorators":true,"jsx":2,"module":1,"noImplicitOverride":true,"outDir":"./","skipLibCheck":true,"sourceMap":true,"strict":true,"stripInternal":true,"target":5},"fileIdsList":[[80,82],[84],[86],[87],[88,96,97,104,113],[88,89,96,104],[90,123],[91,92,97,105],[92,113],[93,94,96,104],[94],[95,96],[96],[96,97,98,113,122],[97,98],[99,104,113,122],[96,97,99,100,104,113,116,122],[99,101,113,116,122],[84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,122,123,124,125,126,127,128,129],[96,102],[103,122],[94,96,104,113],[105],[106],[86,107],[108,118],[109],[110],[96,111],[111,112,123,125],[96,113],[114],[115],[104,116],[117],[104,118],[110,122],[123],[113,124],[125],[126],[96,98,113,122,125,127],[113,128],[76,77],[76,77,78,79],[81],[119,120],[61,62,63],[62],[63,66],[61],[63],[61,63,68,69,96],[62,63,65,66,68,69,71,72,73],[63,71],[62,96],[49],[49,50],[45,46,47,48,51,52,53,54,55,56,57,58,59,60]],"referencedMap":[[83,1],[84,2],[86,3],[87,4],[88,5],[89,6],[90,7],[91,8],[92,9],[93,10],[94,11],[95,12],[96,13],[97,14],[98,15],[99,16],[100,17],[101,18],[130,19],[102,20],[103,21],[104,22],[105,23],[106,24],[107,25],[108,26],[109,27],[110,28],[111,29],[112,30],[113,31],[114,32],[115,33],[116,34],[117,35],[118,36],[122,37],[123,38],[124,39],[125,40],[126,41],[127,42],[128,43],[78,44],[80,45],[79,44],[82,46],[121,47],[64,48],[63,49],[67,50],[66,51],[68,52],[70,53],[74,54],[69,2],[75,55],[71,49],[72,56],[47,13],[50,57],[51,58],[61,59]],"exportedModulesMap":[[83,1],[84,2],[86,3],[87,4],[88,5],[89,6],[90,7],[91,8],[92,9],[93,10],[94,11],[95,12],[96,13],[97,14],[98,15],[99,16],[100,17],[101,18],[130,19],[102,20],[103,21],[104,22],[105,23],[106,24],[107,25],[108,26],[109,27],[110,28],[111,29],[112,30],[113,31],[114,32],[115,33],[116,34],[117,35],[118,36],[122,37],[123,38],[124,39],[125,40],[126,41],[127,42],[128,43],[78,44],[80,45],[79,44],[82,46],[121,47],[64,48],[63,49],[67,50],[66,51],[68,52],[70,53],[74,54],[69,2],[75,55],[71,49],[72,56],[47,13],[50,57],[51,58],[61,59]],"semanticDiagnosticsPerFile":[83,84,86,87,88,89,90,91,92,93,94,95,96,97,98,85,129,99,100,101,130,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,122,123,124,125,126,127,128,76,78,80,79,77,82,81,119,120,121,11,10,2,12,13,14,15,16,17,18,19,3,4,23,20,21,22,24,25,26,5,27,28,29,30,6,31,32,33,34,7,39,35,36,37,38,8,43,40,41,42,1,9,44,64,63,65,67,66,68,70,74,69,75,71,72,62,73,45,46,47,48,49,50,51,52,61,53,54,55,56,57,59,58,60]},"version":"4.5.3"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/async",
3
- "version": "2.23.1-dev.ed17952c",
3
+ "version": "2.23.1-dev.f5b1145e",
4
4
  "description": "Async utils.",
5
5
  "bugs": {
6
6
  "url": "'https://github.com/dxos/protocols/issues"
@@ -18,7 +18,7 @@
18
18
  "src"
19
19
  ],
20
20
  "dependencies": {
21
- "@dxos/debug": "2.23.1-dev.ed17952c"
21
+ "@dxos/debug": "2.23.1-dev.f5b1145e"
22
22
  },
23
23
  "devDependencies": {
24
24
  "@dxos/toolchain-node-library": "2.23.0",
@@ -6,9 +6,22 @@
6
6
 
7
7
  import { expectToThrow } from '@dxos/debug';
8
8
 
9
- import { sleep, promiseTimeout, timeout, waitForCondition } from './async';
9
+ import { sleep, promiseTimeout, waitForCondition } from './async';
10
10
  import { trigger } from './trigger';
11
11
 
12
+ const timeout = (f: Function, timeout = 0) => new Promise((resolve, reject) => {
13
+ const handle = setTimeout(async () => {
14
+ try {
15
+ const value = await f();
16
+ resolve(value);
17
+ } catch (err) {
18
+ reject(err);
19
+ } finally {
20
+ clearTimeout(handle);
21
+ }
22
+ }, timeout);
23
+ });
24
+
12
25
  test('sleep', async () => {
13
26
  const now = Date.now();
14
27
 
@@ -17,7 +30,7 @@ test('sleep', async () => {
17
30
  });
18
31
 
19
32
  test('trigger', async () => {
20
- const [value, setValue] = trigger();
33
+ const [value, setValue] = trigger<any>();
21
34
 
22
35
  const t = setTimeout(() => setValue('test'), 10);
23
36
 
@@ -30,13 +43,13 @@ test('trigger', async () => {
30
43
  test('promiseTimeout', async () => {
31
44
  {
32
45
  const promise = timeout(() => 'test', 100);
33
- const value = await promiseTimeout(promise, 200);
46
+ const value = await promiseTimeout(promise, 200, new Error('timeout'));
34
47
  expect(value).toBe('test');
35
48
  }
36
49
 
37
50
  {
38
51
  const promise = timeout(() => 'test', 200);
39
- await expectToThrow(() => promiseTimeout(promise, 100));
52
+ await expectToThrow(() => promiseTimeout(promise, 100, new Error('timeout')));
40
53
  }
41
54
  });
42
55
 
package/src/async.ts ADDED
@@ -0,0 +1,80 @@
1
+ //
2
+ // Copyright 2020 DXOS.org
3
+ //
4
+
5
+ import { trigger } from './trigger';
6
+
7
+ /**
8
+ * Times out after delay.
9
+ */
10
+ export const sleep = (ms: number) => new Promise<void>((resolve) => {
11
+ const finish = Date.now() + ms;
12
+
13
+ // `setTimeout` does not guarantee execution at >= the scheduled time and may execute slightly early.
14
+ const sleeper = () => {
15
+ const delta = finish - Date.now();
16
+ if (delta > 0) {
17
+ setTimeout(sleeper, delta);
18
+ } else {
19
+ resolve();
20
+ }
21
+ };
22
+
23
+ sleeper();
24
+ });
25
+
26
+ /**
27
+ * @param [timeout] How long to wait, in milliseconds (0 = no timeout).
28
+ */
29
+ export const promiseTimeout = <T = any>(promise: Promise<T>, timeout: number, error: Error): Promise<T> => {
30
+ let cancelTimeout: any;
31
+
32
+ const timeoutPromise = new Promise<T>((resolve, reject) => {
33
+ const timer = setTimeout(() => {
34
+ reject(error);
35
+ }, timeout);
36
+
37
+ cancelTimeout = () => {
38
+ clearTimeout(timer);
39
+ };
40
+ });
41
+
42
+ return Promise.race([
43
+ promise,
44
+ timeoutPromise
45
+ ]).finally(() => {
46
+ cancelTimeout();
47
+ });
48
+ };
49
+
50
+ /**
51
+ * Returns a Promise which resolves when `condFn` returns truthy. The value returned by
52
+ * `condFn` is used to resolve the Promise.
53
+ * @param [timeout] How long to wait, in milliseconds (0 = no timeout).
54
+ * @param [interval=10] How frequently to check, in milliseconds.
55
+ */
56
+ export const waitForCondition = (condFn: Function, timeout = 0, interval = 10) => {
57
+ const stopTime = timeout ? Date.now() + timeout : 0;
58
+ const [provider, resolver] = trigger<any>();
59
+ const waiter = async () => {
60
+ // eslint-disable-next-line no-unmodified-loop-condition
61
+ while (!stopTime || Date.now() < stopTime) {
62
+ try {
63
+ // eslint-disable-next-line no-await-in-loop
64
+ const value = await condFn();
65
+ if (value) {
66
+ resolver(value);
67
+ break;
68
+ }
69
+ } catch (e) {
70
+ // Pass...
71
+ }
72
+ // eslint-disable-next-line no-await-in-loop
73
+ await sleep(interval);
74
+ }
75
+ };
76
+
77
+ setTimeout(waiter, 0);
78
+
79
+ return timeout ? promiseTimeout(provider(), timeout, new Error('Timeout')) : provider();
80
+ };
package/src/events.js CHANGED
@@ -47,5 +47,5 @@ export const waitForEvent = (eventEmitter, eventName, test, timeout, error) => {
47
47
  });
48
48
  });
49
49
 
50
- return timeout ? promiseTimeout(promise, timeout, error).finally(off) : promise.finally(off);
50
+ return timeout ? promiseTimeout(promise, timeout, error ?? new Error()).finally(off) : promise.finally(off);
51
51
  };
package/src/async.js DELETED
@@ -1,115 +0,0 @@
1
- //
2
- // Copyright 2020 DXOS.org
3
- //
4
-
5
- import { trigger } from './trigger';
6
-
7
- // TODO(burdon): Remove.
8
- export const noop = (...args) => args;
9
-
10
- /**
11
- * Timesout after delay.
12
- * @param timeout
13
- * @returns {Promise<unknown>}
14
- */
15
- export const sleep = timeout => new Promise((resolve) => {
16
- const finish = Date.now() + timeout;
17
-
18
- // `setTimeout` does not guarantee execution at >= the scheduled time and may execute slightly early.
19
- const sleeper = () => {
20
- const delta = finish - Date.now();
21
- if (delta > 0) {
22
- setTimeout(sleeper, delta);
23
- } else {
24
- resolve();
25
- }
26
- };
27
-
28
- sleeper();
29
- });
30
-
31
- /**
32
- * Async timeout
33
- * @param f
34
- * @param [timeout]
35
- * @returns {Promise<unknown>}
36
- */
37
- export const timeout = (f, timeout = 0) => new Promise((resolve, reject) => {
38
- const handle = setTimeout(async () => {
39
- try {
40
- const value = await f();
41
- resolve(value);
42
- } catch (err) {
43
- reject(err);
44
- } finally {
45
- clearTimeout(handle);
46
- }
47
- }, timeout);
48
- });
49
-
50
- /**
51
- * @param {Promise} promise
52
- * @param {Number} timeout
53
- * @returns {Promise<unknown>}
54
- */
55
- export const promiseTimeout = (promise, timeout, error) => {
56
- let cancelTimeout;
57
-
58
- const timeoutPromise = new Promise((resolve, reject) => {
59
- const timer = setTimeout(() => {
60
- reject(error || new Error(`Timed out in ${timeout} ms.`));
61
- }, timeout);
62
-
63
- cancelTimeout = () => {
64
- clearTimeout(timer);
65
- resolve();
66
- };
67
- });
68
-
69
- return new Promise((resolve, reject) => {
70
- Promise.race([
71
- promise,
72
- timeoutPromise
73
- ]).then((...result) => {
74
- cancelTimeout();
75
- resolve(...result);
76
- }, (err) => {
77
- cancelTimeout();
78
- reject(err);
79
- });
80
- });
81
- };
82
-
83
- /**
84
- * Returns a Promise which resolves when `condFn` returns truthy. The value returned by
85
- * `condFn` is used to resolve the Promise.
86
- * @param {function} condFn
87
- * @param {number} [timeout] How long to wait, in milliseconds (0 = no timeout).
88
- * @param {number} [interval=10] How frequently to check, in milliseconds.
89
- * @returns {*}
90
- */
91
- export const waitForCondition = (condFn, timeout = 0, interval = 10) => {
92
- const stopTime = timeout ? Date.now() + timeout : 0;
93
- const [provider, resolver] = trigger();
94
- const waiter = async () => {
95
- // eslint-disable-next-line no-unmodified-loop-condition
96
- while (!stopTime || Date.now() < stopTime) {
97
- try {
98
- // eslint-disable-next-line no-await-in-loop
99
- const value = await condFn();
100
- if (value) {
101
- resolver(value);
102
- break;
103
- }
104
- } catch (e) {
105
- // Pass...
106
- }
107
- // eslint-disable-next-line no-await-in-loop
108
- await sleep(interval);
109
- }
110
- };
111
-
112
- setTimeout(waiter, 0);
113
-
114
- return timeout ? promiseTimeout(provider(), timeout) : provider();
115
- };