Bitcoin Forum

Bitcoin => Electrum => Topic started by: dave3 on June 02, 2017, 05:19:04 PM



Title: Why does Electrum force a mining fee change?
Post by: dave3 on June 02, 2017, 05:19:04 PM
I just switched to Electrum, and sent my first transaction from it.

I tried to set the mining fee manually, but whether I set the "Use dynamic fees" in the preferences on or off, Electrum still tacked on an additional 9 satoshis to the static mining fee I set.

Not that it's a great amount, but why doesn't it use the static fee I set, and instead adds more to it?



Title: Re: Why does Electrum force a mining fee change?
Post by: kolloh on June 02, 2017, 08:21:44 PM
I just switched to Electrum, and sent my first transaction from it.

I tried to set the mining fee manually, but whether I set the "Use dynamic fees" in the preferences on or off, Electrum still tacked on an additional 9 satoshis to the static mining fee I set.

Not that it's a great amount, but why doesn't it use the static fee I set, and instead adds more to it?



I tested and wasn't able to reproduce this on 2.8.2 . You aren't using a very old version of Electrum, are you?

Settings tested were
https://i.imgur.com/qSmA33v.png

I was able to successfully enter a manual fee and when previewing the transaction, it used exactly what I typed as the fee.

How are you reproducing this issue?


Title: Re: Why does Electrum force a mining fee change?
Post by: dave3 on June 02, 2017, 08:40:27 PM
I'm using Electrum 2.8.2.

This happened with my first transaction, but I did a second transaction, and it used the manual fee I entered the second time.

So I guess I can't reproduce it, but it definitely happened the first time.


Title: Re: Why does Electrum force a mining fee change?
Post by: HCP on June 03, 2017, 08:44:55 AM
I wonder if it might be some weird little rounding error somewhere when calculating the payment, change and fee sizes? 9 satoshi's seems like a really odd amount for it to be "out" by... ???


Title: Re: Why does Electrum force a mining fee change?
Post by: dave3 on June 03, 2017, 09:06:05 AM
Yeah, I don't know.  I misread the decimal points, too, it was actually 90 satoshis.  Also, the balance in my wallet ended in 90 satoshis.


Title: Re: Why does Electrum force a mining fee change?
Post by: TheButterZone on June 03, 2017, 09:21:56 AM
Current version of Electrum is 2.8.3


Title: Re: Why does Electrum force a mining fee change?
Post by: dave3 on June 03, 2017, 10:57:03 AM
I just checked;  it is the latest version I'm using, Electrum 2.8.3.  I just downloaded and installed the latest version a few days ago.

I can reproduce it again now.  It looks like maybe when the end of your balance is 1-99 satoshis, it adds it to your mining fee forcibly.

After my last transaction, my balance ends in 43 satoshis, so I started a Send transaction (didn't actually send it this time).  Here you can see it tacks on the extra 43 satoshis to the fee:

https://i.imgur.com/RaPEcGz.png

It's not a lot now, but it's annoying, and maybe 10 years from now those extra satoshis would buy me lunch.  :)


Title: Re: Why does Electrum force a mining fee change?
Post by: HCP on June 03, 2017, 11:31:38 AM
Ahhhhh that explains it... Electrum is protecting you from yourself ;)

It is preventing your transaction from generating a dust output... having a UTXO of 43 sats sent back to your wallet is just completely pointless... as an input to a new transaction, it would require 148 bytes, at even stupid low fee of 1 sat/byte, you'd need to pay 148 sats, to use that 43 sat UTXO as an input to a transaction.

Now do the math with current fee rates of 300+... all of a sudden, your 43 sat UTXO is going to cost 44,400+ sats to put in a transaction...

be thankful Electrum wants to give it to the miners... it's cheaper :P


Title: Re: Why does Electrum force a mining fee change?
Post by: dave3 on June 03, 2017, 11:46:51 AM
Except it wasn't actually dust.  I had just transferred everything from Bitcoin Core into Electrum with a single transaction.  So everything was under a single address.  The transaction size would still be the same.


Title: Re: Why does Electrum force a mining fee change?
Post by: Abdussamad on June 03, 2017, 12:06:52 PM
Except it wasn't actually dust.  I had just transferred everything from Bitcoin Core into Electrum with a single transaction.  So everything was under a single address.  The transaction size would still be the same.


He's talking about the transaction output not the inputs. Try reading what he wrote again. Electrum has to avoid your wallet filling up with small meaningless amounts that you can't spend. It's why we use software like electrum to manage our coins for us.