synonymdev / bitkit

Self-custodial Bitcoin and Lightning Wallet for Android and iOS.
https://bitkit.to
MIT License
117 stars 21 forks source link

[Bug]: No confetti or transaction activity on requesting spending balance via CJIT #1780

Closed catch-21 closed 1 month ago

catch-21 commented 6 months ago

Describe the bug

Although the channel setup completed (see Created cjitEntry ef5d90a2-7d12-417b-8163-30db71dc814e) I did not see any confetti or transaction activity. After manually refreshing the wallet the balance updated to reflect my new spending balance. After a short wait and restarting the app I still do not see the transaction activity. Other new wallet have not seen this issue. This is occurring on a wallet that recently had a force closure (could be relevant).

It is possible to produce a CJIT invoice, but if Bitkit isn't in the foreground when the invoice is paid then it is possible for it to not detect the 'Received' event. This leads to correct spending balance but no activity to assure the user the payment was received.

Reproduce

  1. Start with a Bitkit wallet with no LN channels
  2. Tap Receive and produce CJIT invoice
  3. Screenshot the invoice
  4. Minimise Bitkit
  5. Scan to pay the invoice from a different wallet. The LN payment will succeed provided Bitkit is still running in the background. If Bitkit has been killed then LN payment fails and the invoice goes from Pending to Holding to Cancelled state.
  6. Now you can kill Bitkit (or leave it for the OS to dispose of after some time)
  7. Start Bitkit again
  8. Observe new spending balance, but no confetti and no 'Received' activity item. Also observe open Lightning connection in Advanced settings.

Screenshots / Recording

This shows my correct balance and LN channel is open but no transaction activity

https://github.com/synonymdev/bitkit/assets/74595920/34274d3d-c245-40ab-965b-608d607527ba

Operating system

Android/iOS

Bitkit version

1.0.4 (135)

Log output

bitkit_ldk_logs_1714731123960.zip

limpbrains commented 5 months ago

I can't reproduce this issue

limpbrains commented 5 months ago

I conducted extensive testing. Opened 5 channels with CJIT. Received several payments. I always get confetti. If this issue does not recur in the next testing session, we can consider it resolved. It could be linked to the wallet's malfunction or another unknown cause.

JeanlChristophe commented 5 months ago

Same. Closing the ticket.

JeanlChristophe commented 2 months ago

Joe has a similar issue, except that its balance is not updated.

pwltr commented 2 months ago

Attempted to fix in https://github.com/synonymdev/bitkit/pull/2225, let's move this to the backlog and see if it still occurs.

catch-21 commented 1 week ago

Verified on 1.0.6 (138) Followed the steps from description. When CJIT channel is opened whilst Bitkit is minimised and then killed off the correct spending balance and received activity is displayed when reopened. No confetti, but I think that is expected given the app has been restarted.