Improve ChannelDetails readability significantly. 2021-07-chan-details-usability
authorMatt Corallo <git@bluematt.me>
Tue, 6 Jul 2021 23:41:27 +0000 (23:41 +0000)
committerMatt Corallo <git@bluematt.me>
Thu, 8 Jul 2021 16:46:57 +0000 (16:46 +0000)
commit2b08a47e887913c8b056192d5b9df4569cf32548
treeb939eba0605cfb9a9b8358230452c184c8a2513f
parent431f807907ae390a255641719dd5cb3279bc9d5b
Improve ChannelDetails readability significantly.

After the merge of #984, Jeff pointed out that `ChannelDetails` has
become a bit of a "bag of variables", and that a few of the variable
names in #984 were more confusing than necessary in context.

This addresses several issues by:
 * Splitting counterparty parameters into a separate
   `ChannelCounterpartyParameters` struct,
 * using the name `unspendable_punishment_reserve` for both outbound
   and inbound channel reserves, differentiating them based on their
   position in the counterparty parameters struct or not,
 * Using the name `force_close_spend_delay` instead of
   `spend_csv_on_our_commitment_funds` to better communicate what
   is occurring.
fuzz/src/router.rs
lightning-invoice/src/utils.rs
lightning/src/ln/channelmanager.rs
lightning/src/routing/router.rs