Open
Description
Our current channel code is functional but is a bit bloated and it would be great to clean it when we do any accounting changes (like buffer spikes, anchor output), understanding correctness of our channel policy or state machines.
Opening this issue to track all changes we may find desirable:
- Rename channel variables (see Rename a's keys as local's keys and b's keys as remote's keys #633)
- Rename, document channel/inbound_htlc/outbound_htlc state machines
- Split channel state machine from htlc ones (
AwaitingRemoteRevokeToAnnounce
/AwaitingAnnouncedRemoteRevoke
must die) - Document and verify accounting logic (see as a starter ariard@9697578, also logs rust-bitcoin http://gnusha.org/rust-bitcoin/2020-06-11.log)
- Encapsulate channel variables by logic with safe methods
- Split
build_commitment_transaction
between accounting and transaction generation, the second is a function of the one - ?
(Tagging this at good first issue, some items on this list like documentation are really good starters to understand LN internals well)
Metadata
Metadata
Assignees
Labels
No labels