-
Notifications
You must be signed in to change notification settings - Fork 138
Open
Labels
Description
Problem
Recent changes (285743f, 39405ea) in tapgarden downgraded several critical errors (in inspectWalletTx, receiveProofs, etc.) to logs to prevent daemon crashes. However, this means these errors are now invisible to UI/API clients, potentially leaving users unaware of failed asset transfers or imports.
Analysis
- Current Behavior: Errors in
Custodian.mainEventLoop(specifically duringinspectWalletTx,mapProofToEvent,handleMailboxMessages, andreceiveProofs) are logged, and the loop continues. - Existing Infrastructure:
tapgardenhas anAssetReceiveEventwhich includes anErrorfield.NewAssetReceiveErrorEventhelper exists.SubscribeReceiveEventsRPC is already capable of mapping this internal error field to theReceiveEventprotobuf messageerrorfield.
- Gap: The code currently logs the error instead of publishing an
AssetReceiveErrorEventin these specific failure paths.
Proposal
Instrument the Custodian to publish AssetReceiveErrorEvent before logging and continuing in the following areas:
inspectWalletTx: Whenaddress.NewTransferFromWalletTxorGetOrCreateEventfails.mapProofToEvent: WhenGetOrCreateEventfails (currently only logs).handleMailboxMessages: When processing specific messages fails.
This will utilize the existing SubscribeReceiveEvents RPC stream to notify clients of these failures without requiring protocol changes.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
🆕 New