lightningdevkit / rust-lightning

A highly modular Bitcoin Lightning library written in Rust. It's rust-lightning, not Rusty's Lightning!
Other
1.17k stars 368 forks source link

Expose current dust exposure #2264

Open TheBlueMatt opened 1 year ago

TheBlueMatt commented 1 year ago

re: #2261 we should also ideally expose what our current dust exposure in a channel is

ariard commented 1 year ago

By exposure do you mean at the counterparty-level or at the network-level? Unclear to me without spec modifications.

TheBlueMatt commented 1 year ago

The dust exposure we have on our current channel which is limited by the config knob.

ariard commented 1 year ago

So announce max_dust_htlc_exposure_msat as a new open_channel/accept_channel param or as a new BOLT7 channel_update param ? Or something different ?

wpaulino commented 1 year ago

So announce max_dust_htlc_exposure_msat as a new open_channel/accept_channel param or as a new BOLT7 channel_update param ? Or something different ?

I think this is just meant to expose the current value as part of ChannelDetails.

acceleratesage commented 1 month ago

Is this still needed after https://github.com/lightningdevkit/rust-lightning/pull/2442?

vincenzopalazzo commented 1 month ago

Is this still needed after https://github.com/lightningdevkit/rust-lightning/pull/2442?

Looks like no https://docs.rs/lightning/latest/lightning/ln/channel_state/struct.ChannelDetails.html

TheBlueMatt commented 1 month ago

Well, it wasn't needed, but now it is again....the dust exposure used to just be the sum of dust HTLCs, however in more recent releases it also considers the channel's commitment transaction fee. Ideally we should expose both as a single amount.