You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are 4 usages of WalletRepositoryImpl, in 3 of these usages it is explicitly supplied with db instances. Only one adds a fallback in to in-memory storage, the default for this place is db as well.
This umbrella predates the offline-first ContractManager/repository architecture, which has since absorbed most of it. Mapping the original checklist to where things stand on master:
[~] getVtxos use the db — reads now route through contractManager.getContractsWithVtxos() (wallet.ts:1035,1076), but three call sites still read VTXO state directly from the indexer (fetchPendingTxswallet.ts:1551, finalizePendingTxswallet.ts:3846, the getTxCreatedAt callback wallet.ts:1082). Tracked separately in Wallet bypasses ContractManager with direct IndexerProvider reads in three places #550 — that's the remaining work for this item.
[~] getUtxos use the db — walletRepository.getUtxos() is used (wallet.ts:4755), but on-chain/boarding coins are still fetched live from Esplora (onchainProvider.getCoinswallet.ts:1337).
Save tx history in db — done: saveTransactions is implemented across all backends and invoked on sync (wallet.ts:4631, and in the SW handler).
What's genuinely left under this issue (not covered elsewhere): persisting boarding txs + outspents in the DB instead of re-fetching from Esplora, and closing out the last direct-indexer getVtxos reads (the latter = #550).
Keeping this open as the tracking umbrella. The two concrete unaddressed items above are the actionable remainder; everything else here is either done or has a dedicated issue (#550, #493, #585).
Activity
shubertm commentedon Feb 5, 2026
@bordalix can I take up this issue?
bordalix commentedon Feb 5, 2026
@shubertm sure
shubertm commentedon Feb 7, 2026
DB Usage Verification
WalletRepositoryImpl
There are 4 usages of WalletRepositoryImpl, in 3 of these usages it is explicitly supplied with db instances. Only one adds a fallback in to in-memory storage, the default for this place is db as well.
ts-sdk/src/wallet/serviceWorker/wallet.ts
Lines 89 to 100 in f139452
ts-sdk/src/wallet/serviceWorker/worker.ts
Lines 126 to 135 in f139452
ts-sdk/src/wallet/serviceWorker/worker.ts
Lines 200 to 212 in f139452
ts-sdk/src/wallet/wallet.ts
Lines 221 to 224 in f139452
ContractRepositoryImpl
There are 2 usages of ContractRepositoryImpl, both of them are supplied with db instances
ts-sdk/src/wallet/serviceWorker/wallet.ts
Lines 89 to 100 in f139452
ts-sdk/src/wallet/wallet.ts
Lines 221 to 224 in f139452
pietro909 commentedon Jul 16, 2026
Status update (2026-07)
This umbrella predates the offline-first ContractManager/repository architecture, which has since absorbed most of it. Mapping the original checklist to where things stand on
master:contractManager.getContractsWithVtxos()(wallet.ts:1035,1076), but three call sites still read VTXO state directly from the indexer (fetchPendingTxswallet.ts:1551,finalizePendingTxswallet.ts:3846, thegetTxCreatedAtcallbackwallet.ts:1082). Tracked separately in Wallet bypasses ContractManager with direct IndexerProvider reads in three places #550 — that's the remaining work for this item.walletRepository.getUtxos()is used (wallet.ts:4755), but on-chain/boarding coins are still fetched live from Esplora (onchainProvider.getCoinswallet.ts:1337).saveTransactionsis implemented across all backends and invoked on sync (wallet.ts:4631, and in the SW handler).onchainProvider.getTransactions/getTxOutspends(wallet.ts:1156-1177); it is not persisted. (Related dedup/correctness fixes landed in fix: suppress duplicate history entries for swept boarding deposits #530, [codex] Fix duplicate boarding refill history entries #531, fix(wallet): phantom receive inflation from boarding sweeps (Esplora outspends without txid) #587, but none persist the boarding tx set.)What's genuinely left under this issue (not covered elsewhere): persisting boarding txs + outspents in the DB instead of re-fetching from Esplora, and closing out the last direct-indexer
getVtxosreads (the latter = #550).Keeping this open as the tracking umbrella. The two concrete unaddressed items above are the actionable remainder; everything else here is either done or has a dedicated issue (#550, #493, #585).