From: Chris Duncan Date: Sun, 9 Aug 2026 20:57:54 +0000 (-0700) Subject: Hard-cap wallet account derivation batch at 1000, now matches documentation. X-Git-Url: https://git.codecow.com/?a=commitdiff_plain;h=bd5247923d0065b27d1b222dd07e8474bdc031a8;p=libnemo.git Hard-cap wallet account derivation batch at 1000, now matches documentation. --- diff --git a/src/lib/wallet/accounts.ts b/src/lib/wallet/accounts.ts index 21a0164..b437829 100644 --- a/src/lib/wallet/accounts.ts +++ b/src/lib/wallet/accounts.ts @@ -21,11 +21,11 @@ export async function _accounts (type: WalletType, accounts: Map 1_000) { + if (to - from > 100) { console.warn('libnemo performance may degrade when deriving many accounts at once') } - if (to - from > 10_000) { - throw new RangeError('Maximum 10,000 accounts per call') + if (to - from > 1_000) { + throw new RangeError('Maximum 1000 accounts per call') } const output = new Map() const missing: number[] = []