bitkit
bitkit copied to clipboard
[Bug]: Amount doesn't display when I create a TX to myself
Describe the bug
I tried to make a transaction (max amount) to a single bech32 adress and it works. But :
- In the activity there is no amount, only "Sent"
- when you click on this transaction, there is no information about it.
Reproduce
- Go to 'send'
- Click on 'max amount
- Click on 'Send
- Scroll down to 'activity'
- See error
Screenshots / Recording
Operating system
Graphene OS, iOS
Bitkit version
v47
Log output
No response
A design decision was made to remove all fees from from the activity list amounts to show the user exactly what they sent. Originally in this type of scenario, Bitkit would only show the fee that the user payed to themself (Ex: -500 sats). A compromise on this could be to show the fee, as before, in the event the sent/received amount is 0 or label it as "Self Payment".
Why can't we show two tx? One outgoing with the amount that was sent, and one incoming tx, with the same amount received? This is how most wallets do it. -10000 sats, +10000 sats (amount sent/received). The fee is unrelated. As a bonus, if the app is able to detect self sends, we could perhaps attach the user profile to the txs to indicate a self send/receive.
Indeed, it would be nice.
This solution may be a bit confusing to the user since it looks like two transactions when technically it is only one. On the dev side, this would also add a lot of logic to the on-chain list item compared instead to a simple "Sent to Self" label.
While it's technically a single transaction, conceptually and mentally it's understood as two parts by regular joe. When a user sends funds, they naturally anticipate a decrease in their wallet balance. And when it concerns a self send, they also expect these funds to re-enter their wallet. This interpretation aligns with the handling of self-sends by most wallets and resonates with conventional transactional concepts. If needed, we can delve deeper into this topic during a UX call, should you believe this design decision could benefit from a broader range of perspectives.
This will break the second we start sending sats to a third output that is not our own (Example given below). We may need to delve a bit deeper into this for an optimized UX. For the next UX call I propose we revert back to displaying the fee in the activity list so we can accurately show how much a user sent or received in a given transaction and so that everything adds up as expected. For self-sends, they should technically be "Sent" transactions, display the fee+sent sats of the transaction and then labeled as "Self Send" or "Partial Self Send" (if more sats were sent to another party as well) depending.
For example, I have a wallet with a single utxo valued at 100,000 sats. Lets create a transaction with this utxo to two parties, Alice and myself. 50,000 sats goes to Alice, 20,000 sats to me and a fee of 5,000 sats. This create a transaction with 1 input and 3 outputs (Alice (50,000), Myself(20,000) & Change(25,000)). For me the sender, the matched input value of 100,000 is greater than the matched output value 20,000(excludes change). This means that the user technically sent funds Alice (50,000) + Fee (5,000) = 55,000 sats sent.
On Alice's side of the transaction, however, her matched inputs (0) are less than her matched outputs (50,000) so she received funds.
Closing this ticket. It's including in the Prototype v41. Thanks for the work.
https://github.com/synonymdev/bitkit/issues/1556#issuecomment-1979423048
"I would argue the following activity log and overall balance situation is confusing, which is why I'm pushing back against separate activity row entries such as this:
Balance: 30000
Activity Log:
Sent To Self: 9,500
Sent: -5000
Received: 15,000
Received: 20,000
Adding sent-to-self values as a sub-entry of the single activity item is more consistent with the current design of the activity list and doesn't make it look like a separate/additional transaction has occurred." from @coreyphillips
Checked on 2c5b07726fd35cb796a9566c47d0f6c36fda4ef4 To have a 'sent to myself' activity is defined in v47 design spec but is not included in implementation of v47
closing it's issue. Including into https://github.com/orgs/synonymdev/projects/12/views/1?pane=issue&itemId=62269366