I've learned something really interesting tonight, it's called the gap limit problem.
The background story is I received a new payment in BTCpay today, but it's not showing up in my external wallet! so strange, and to make it even more strange, the newly created address is not even "matching" on the address lists in my wallet.
Basically the BTCpay dashboard shows the new payment and confirmed, also shows the correct balance, but no new tx in my wallet, ugh - where are my missing sats? 🕵🏼
After checking and asking around, I found out there is a thing called the gap limit problem!
The majority of third party wallets are light wallets, which share a node between many users. To prevent performance issues, both light and full node reliant wallets limit the amount (typically 20) of addresses without balance that they track on the blockchain. BTCPay Server generates a new address for every invoice.
With above in mind, after BTCPay Server generates 20 consecutive unpaid invoices, the external wallet stops fetching the transactions, assuming no new transactions occurred. Once 21st, 22nd, etc invoices are paid, your external wallet won't show them.
On the other hand, internally, BTCPay Server wallet tracks any address it generates itself along with a much greater gap limit.
so the solution I found is toincrease the gap limit. Currently, you can do this only in two wallets: Electrum or Wasabi; I used Electrum for it, and more details are here:)
thanks for sharing! Electrum is the best wallet
reply