authorclover caruso <git@paperclover.net> 2026-10-12 14:56:47-07:00
committerclover caruso <git@paperclover.net> 2026-10-12 15:00:13-07:00
log5f3f3f2f854cf5390a4de275574db4a8d4a4cf8c
treeacadca0225e51451f7c7beba1e88986a8ea8f037
parent3c3cdcccc9b633ab2ea0e14158e780bab6bbed15
signature Signed by SSH key SHA256:cOKiuRFOeSRxne6EWgHtdQQSlBxjOXm2hOCFnCdLQbQ (~clover)

fix: avoid the finally trap

closes #108

3 files changed, 6 insertions(+), 3 deletions(-)

lib/async.ts+1-1
......@@ -152,7 +152,7 @@ export class DedupeConcurrent<Args extends unknown[], Ret> {
152152 if (promise) return promise;
153153 promise = this.fn(...args);
154154 this.pending.set(k, promise);
155 void promise.finally(() => void this.pending.delete(k));
155 void promise.finally(() => void this.pending.delete(k)).catch(() => {});
156156 return promise;
157157 };
158158}
lib/readme.changes.md+5
......@@ -10,6 +10,11 @@
1010 - finally fixes resize corruptions for long running widgets
1111- `string/ansi`: add `inverse`, `resetInverse`, and `cursorHome`.
1212
13### fixes
14
15- `async.DedupeConcurrent` no longer causes unhandled rejections with correct
16 caller error handling.
17
1318## v7
1419
1520### features
lib/repl.ts-2
......@@ -18,8 +18,6 @@
1818 * // ...
1919 * },
2020 * },
21 *
22 * // many more options to customize how it displays
2321 * });
2422 *
2523 * import * as repl from "@clo/lib/repl";