Pages:
Author

Topic: Transaction fees magically appearing, how to account for them? - page 3. (Read 7480 times)

newbie
Activity: 11
Merit: 0
Would it not be better to make the transaction fee user-setable instead of "programmatically" set?  Have we not already established that these transactions are perfectly valid without a fee, they just may take longer to get processed.

This way the price discovery of the transaction fee is moved into the app developers instead of the Bitcoin source code.
hero member
Activity: 602
Merit: 513
GLBSE Support [email protected]
The code to calculate the tx fee is already present in bitcoin (obviously) so wrapping an RPC call around it should be quite simple.
+1
hero member
Activity: 588
Merit: 500
The code to calculate the tx fee is already present in bitcoin (obviously) so wrapping an RPC call around it should be quite simple.
newbie
Activity: 3
Merit: 0
There's actually a small issue with this accounting algorithm - if we don't know the transaction fee before hand, we can't actually ensure the user's account has a large enough balance to cover the transaction.  If their account has 0.25 BTC, and they try to transfer out the entire amount, the merchant would be risking the transaction fee when they executed the transaction.  At .25 BTC it's not a big deal, but as the sums go up the risk increases substantially.

I looked at the code, and it seems pretty easy to write an RPC call "estimatetxfee".  Before I get too deep into doing any development work, is this a realistic approach, or would the chance of the fee changing (especially for larger transactions) make this worthless?  Would it be possible to calculate a maximum possible transaction fee for a given amount taking into account the coins currently in the wallet?

Thanks for any help!
member
Activity: 98
Merit: 13
Considering that the fee is now quite expensive compared to what it has historically been, it really needs to be revisited.

Already revisited, see this thread: https://bitcointalksearch.org/topic/rfc-new-tx-fee-00005-btc-7749

hero member
Activity: 588
Merit: 500
Considering that the fee is now quite expensive compared to what it has historically been, it really needs to be revisited.
legendary
Activity: 1652
Merit: 2301
Chief Scientist
Oh, and what version of bitcoin are you running?  0.3.21 includes a patch from luke-jr that modifies the coin-selection algorithm to avoid sub-cent change when possible.

It will also help if you keep a good selection of 'old' coins in the shared wallet.

I agree that transaction fee accounting/handling needs improvement.
hero member
Activity: 602
Merit: 513
GLBSE Support [email protected]
However, when the user withdrew 9.99000001btc there was a fee of 0.01.
So probably a 10BTC transaction was the input, and the change of 0.00999999 incurred the fee.

Oh For F*cks sake(sorry, just pissed off at this gotcha).

gavinandresen, thanks for the details, I'll implement it that way.
donator
Activity: 826
Merit: 1060
However, when the user withdrew 9.99000001btc there was a fee of 0.01.
So probably a 10BTC transaction was the input, and the change of 0.00999999 incurred the fee.
legendary
Activity: 1652
Merit: 2301
Chief Scientist
The send RPC methods return a transaction id.

Pass the transaction id to the gettransaction RPC method, and it will give you details of the transaction, including what fees were paid.
hero member
Activity: 602
Merit: 513
GLBSE Support [email protected]
I have set my client to pay 0.0 for transaction fees, and to not send amounts smaller than 1btc.

The only reason I'm doing this is to avoid transaction fees so I don't have to deal with them in my system accounts that's keeping track of a users balance.

However, when the user withdrew 9.99000001btc there was a fee of 0.01.

It's really f*cking up my accounting when bitcoind just takes fee's out, it wouldn't be a problem if there was an easy way to find out what the transaction fee was when the transaction happens.

So there seems to be no way to avoid transaction fees at all(I don't mind), is there a way to find out what fee is being paid when the transaction happens?
Pages:
Jump to: