-
Notifications
You must be signed in to change notification settings - Fork 38.3k
Lower default relay fees #13922
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lower default relay fees #13922
Conversation
|
Concept ACK |
|
This was more complicated than I expected, so careful review would probably be a good idea. Possible things worth focusing on:
|
Reviewers, this pull request conflicts with the following ones:
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first. |
src/policy/fees.cpp
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit (here and below): You could use a C++11 for-each loop.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit now applies to #13990
src/test/mempool_tests.cpp
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of changing all the constants in this test, couldn't you set the global min relay fee at the start of the test to 1000 and then back to what it was initially at the end of the test?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought it made more sense to check the default behaviour works right, though that would be plausible too
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If tests don't already run in parallel, it would be nice if they did someday...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@luke-jr just curious, why? Running in parallel makes it harder to debug and reason about.
src/wallet/rpcwallet.cpp
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Should be snake_case: tx_fee_rate.
Also, could submit this feature independent of this pull request, i.e. create a separate pull request.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in independent PR #13988
src/rpc/net.cpp
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing test. Also, this feature should probably be submitted in separate pull request.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test added in separate #13987
|
"it changes the min tx fee to 200 s/B, and the incremental relay fee to 100 s/B" I think you mean |
src/policy/fees.cpp
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: whitespace
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ugh, those weren't meant to be committed in the first place...
|
Concept ACK. Mind adding a release note? |
|
Rebased and release note added |
doc/release-notes-13922.md
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo found by codespell: propogate
42e2af5 to
56251ce
Compare
test/functional/mempool_limit.py
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
./test/functional/mempool_limit.py:16:70: E231 missing whitespace after ','
Some tests assume a minrelaytxfee of 1000 satoshi/kB, so explicitly set that in preparation for lowering the default.
This changes the fee defaults to:
BLOCK_MIN_TX_FEE = 200
DEFAULT_MIN_RELAY_TX_FEE = 200
DEFAULT_INCREMENTAL_RELAY_FEE = 100
DEFAULT_TRANSACTION_MINFEE = 1000
WALLET_INCREMENTAL_RELAY_FEE = 5000
These reduce default minimum network fees by a factor of 5 (from 1000s/kB
to 200s/kB), which matches previous decreases in lowering the price of
block data in USD to about 1c/kB:
2013-05: 50,000 to 10,000 at $100 USD/BTC: 5c/kB to 1c/kB
2014-11: 10,000 to 1,000 at $700 USD/BTC: 7c/kB to 0.7c/kB
2015-10: 1,000 to 5,000 and back to 1,000 at $250 USD/BTC:
0.25c/kB to 1.25c/kB to 0.25c/kB
2018-08: 1,000 to 200 at $6000 USD/BTC: 6c/kB to 1.2c/kB
(Note that on a per-transaction basis, the witness discount generally
decreases fees by about a further 50%, so for individual's a better
comparison might be 3c/kB to 0.6c/kB)
The incremental relay fee is lowered further, to allow cheaper updates
of transactions, which makes better use of blockspace.
Because it will take time for the network to broadly support these lower
mining and relay fees, the wallet defaults are left unchanged at 1000s/kB
and 5000s/kB.
56251ce to
a04a014
Compare
|
Rebased due to conflict in python tests; fixed formatting nit; fixed amount typo in changes to mempool test (7000/5 is 1400 not 1500). |
|
Repeating some in-person comments:
|
|
Closing for now pending further progress on #13990, intending to reopen or refile later |
|
@ajtowns It's been two years, and The mempool has been emptying pretty much every week, and often every day. With LN interest catching on there is a larger need for "next-day" ultra-low fee on-chain TXNs. |
In the meeting of 2018-07-05, we discussed dropping the minimum fee rate below 1000 satoshi/kB. This patch set does only that, leaving related features for other PRs.
There's a bit more of an explanation for some of the choices in the individual commit messages.
Related PRs: