Closed eliotcougar closed 2 months ago
Thanks for the report Eliot! Looking into this on our end, will let you know if we need more details.
I have tried to reproduce this and was not able to. I tested on regtest and testnet and the fees were calculated correctly.
Since the fee is pulled directly from loopd
, can you check the CLI output of loop listswaps
for this swap to see what value is returned for cost_server
?
Since the fee is pulled directly from
loopd
, can you check the CLI output ofloop listswaps
for this swap to see what value is returned forcost_server
?
cost_server
for that swap shows as -1899024
…
PS: Can it be related to taproot?.. It's my first swap using taproot…
Ah ok, that explains where this value is coming from in the UI. I'm not sure if this is related to taproot swaps but that may be a hint. I'll ping the Loop team to see if someone can assist further.
Just wanted to say that I've just updated to 0.10.5... There was a database migration... Then I deleted all cookies and site data for the Terminal Web, reconnected with a new pairing phrase, and let it repopulate the data...
The 1900000 sat profit is still there, and there's the same -1899024 cost_server
in the listswaps
output...
Thanks for the update. I have spoken with the Loop team and it appears that the cost_server
value shouldn't be used in profit calculations. We'll need to implement a fix on the Terminal side to use a different method to determine the cost of a swap. It'll use the amount sent minus the amount received instead.
Hey Eliot, really appreciate the feedback here. We're going to work on getting a fix in for this over the course of the next week or so. Just wanted to let you know that we ack the issue and are prioing a fix, but that's the timeline that we're looking at so that you have full vis and know what to expect next :)
I believe this was fixed on the Loop backend via the following changes. https://github.com/lightninglabs/loop/pull/751 https://github.com/lightninglabs/loop/pull/764 But, let me know if you're still seeing it.
After performing a Loop In, the Terminal Web summary shows obviously wrong data. CSV export table also shows the Looped In amount in the Fee column. It appeared as profit only after the swap server swiped the funds from the address yesterday…
7/26/2023, 11:20:35 AM | 1899024 | Loop In 1,900,000 sats (swap server) | swap_id=06ddda4c1d2658813739d7f6b00945114faa389ea947edb4da3ed72b946c6fba
Swap address: bc1ptrz6ktle0uk56eq2v3jv9yhq6a6sdr2tdg6ta4d0vfjqswmjkhvqcy6vpp
Expected behavior
Loop In shouldn't be counted as profit.
To reproduce
Do a Loop In, wait for it to complete.
System information litd 0.10.4, with external LND on Windows 10...