Skip to content
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

update to minimum fee rate #1036

Merged
merged 2 commits into from Oct 26, 2021
Merged

Conversation

pradyuman-verma
Copy link
Contributor

Resolves #1017
This PR tries to resolve the hard minimum fee rate in bcoin, previously this rate was 100 sat/kb (unchanged since 2017 before segwit), but after segwit, this has to update as for a segwit transaction in SPV mode, which doesn't have any fee estimation method. Therefore SPV mode uses the hardcoded minimum fee rate (100 sat/kbyte), which is too much for a segwit transaction.

@@ -477,7 +477,7 @@ main.minRelay = 1000;
* @default
*/

main.feeRate = 100000;
main.feeRate = 1000;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree we need to lower it from 100 sat / kB but I think 1 sat / kB might be too low. It's a hard thing to set because we don't want users over paying but also (without RBF in bcoin) we don't want users TXs getting stuck for a week. Bitcoin Core used to have a fallback fee of 0.0002 BTC/kB (2000 sat/kB). They have removed that hard coded value and require users to set it themselves.

What do you think about setting this to 2000 or 5000 instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is 1sat/byte, formerly it was 100sat/byte, but yeah, 1sat/byte is relatively low.
5sat/byte fits the curve.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry lol, fee rate units are the worst! Ok I am going to change this value to 5000 then and merge. Thank you!

@codecov-commenter
Copy link

Codecov Report

Merging #1036 (ba609ea) into master (cf7da94) will not change coverage.
The diff coverage is 100.00%.

❗ Current head ba609ea differs from pull request most recent head fae9c7f. Consider uploading reports for the commit fae9c7f to get more accurate results
Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1036   +/-   ##
=======================================
  Coverage   65.40%   65.40%           
=======================================
  Files         156      156           
  Lines       26075    26075           
=======================================
  Hits        17055    17055           
  Misses       9020     9020           
Impacted Files Coverage Δ
lib/protocol/networks.js 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cf7da94...fae9c7f. Read the comment docs.

@pinheadmz pinheadmz merged commit 531fb92 into bcoin-org:master Oct 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants