Post
Topic
Board Electrum
Merits 12 from 3 users
Re: how to access missing balances at higher indexes
by
pooya87
on 18/03/2025, 03:17:02 UTC
⭐ Merited by hosemary (4) ,Abdussamad (4) ,ABCbits (4)
Code:
wallet.change_gap_limit(50000)
After I clicked the Addresses tab, Electrum got stuck. I killed it after eating 1 CPU core for 1.5 hours.
Your UI is basically generating 50000 objects and rendering them to have a "graphic representation" and UIs are not designed to render so many objects Tongue

Actually you don't have to change the gap limit at all. You can use the following command in the console to get the private key for a specific index:

Code:
getprivatekeyforpath("m/0'/50000")

I didn't know about this command. Thanks for sharing that, but I think you should remove the apostrophe after the 0 and the command should be getprivatekeyforpath("m/0/50000"). Otherwise, you will get an incorrect private key.

Please correct me, if I am missing something.
You are onto something. Let me complete it a little.
The derivation path depends on the wallet/mnemonic type. This is its short list:
  • Standard (legacy) wallets @ m/0/
  • SegWit wallets @ m/0'/0/
  • 2FA wallets (both legacy and SegWit) @ m/1'/0/

So if OP's wallet was a legacy one, then command for 50000th address should indeed be getprivatekeyforpath("m/0/50000")