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

Regtest fee control #4629

Merged

Conversation

rustyrussell
Copy link
Contributor

Got a report from @gijswijs that we were sending 0 update_fee on regtest; I've seen this complaint before, but this time we fixed it.

Also, @t-bast wanted to override regtest fees: we used to have a dev option which we removed in favor of direct control, I think that was probably overzealous (it's far easier that writing a bcli replacement!). Of course we recommend this be in the regtest-specific config!

@rustyrussell rustyrussell added this to the v0.10.1 milestone Jul 3, 2021
@rustyrussell rustyrussell requested a review from cdecker as a code owner July 3, 2021 02:42
@rustyrussell rustyrussell force-pushed the guilt/regtest-feecontrol branch from 937dcc5 to 6239684 Compare July 3, 2021 02:47
Copy link
Contributor

@vincenzopalazzo vincenzopalazzo left a comment

Choose a reason for hiding this comment

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

ack 6239684

@t-bast
Copy link

t-bast commented Jul 4, 2021

Thanks, that sounds perfect for the tests I'm doing.

@cdecker
Copy link
Member

cdecker commented Jul 5, 2021

ACK 6239684

@rustyrussell rustyrussell force-pushed the guilt/regtest-feecontrol branch from 6239684 to 431bb42 Compare July 8, 2021 01:20
This has been reported several times on regtest, most recently by Gijs
van Dam.  It turns out approx_max_feerate() was returning 0 in some
corner cases: we should *not* be using that value (as shown, it's
overly conservative) except as a ceiling on fee *increases*.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Changelog-Fixed: Protocol: don't ever send 0 fee_updates (regtest bug).
Useful for regtest and testnet.  Sure, you shouldn't use this on mainnet,
but I haven't restricted it because our users are usually pretty clever.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Fixes: ElementsProject#1806
Changelog-Added: config: `force_feerates` option to allow overriding feerate estimates (mainly for regtest).
@rustyrussell rustyrussell force-pushed the guilt/regtest-feecontrol branch from 431bb42 to 52b1518 Compare July 8, 2021 02:47
'force-feerates' already bypasses this logic, but we should still suppres

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
@rustyrussell rustyrussell force-pushed the guilt/regtest-feecontrol branch from 52b1518 to e55363b Compare July 8, 2021 02:59
@rustyrussell
Copy link
Contributor Author

Ack e55363b

Rebased and fixed (and commented!) code which makes sure we don't reduce, if we're trying to increase and max says were too high already.

@rustyrussell rustyrussell merged commit 30faf96 into ElementsProject:master Jul 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants