mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-08-23 17:47:31 +00:00
add comment re lnchannel channel_states
This commit is contained in:
parent
bb21e01823
commit
a6e3a244e8
1 changed files with 5 additions and 2 deletions
|
@ -58,13 +58,15 @@ if TYPE_CHECKING:
|
|||
|
||||
|
||||
# lightning channel states
|
||||
# Note: these states are persisted by name (for a given channel) in the wallet file,
|
||||
# so consider doing a wallet db upgrade when changing them.
|
||||
class channel_states(IntEnum):
|
||||
PREOPENING = 0 # negociating
|
||||
PREOPENING = 0 # negotiating
|
||||
OPENING = 1 # awaiting funding tx
|
||||
FUNDED = 2 # funded (requires min_depth and tx verification)
|
||||
OPEN = 3 # both parties have sent funding_locked
|
||||
FORCE_CLOSING = 4 # force-close tx has been broadcast
|
||||
CLOSING = 5 # closing negociation
|
||||
CLOSING = 5 # closing negotiation
|
||||
CLOSED = 6 # funding txo has been spent
|
||||
REDEEMED = 7 # we can stop watching
|
||||
|
||||
|
@ -93,6 +95,7 @@ state_transitions = [
|
|||
(cs.FORCE_CLOSING, cs.CLOSED),
|
||||
(cs.CLOSED, cs.REDEEMED),
|
||||
]
|
||||
del cs # delete as name is ambiguous without context
|
||||
|
||||
|
||||
RevokeAndAck = namedtuple("RevokeAndAck", ["per_commitment_secret", "next_per_commitment_point"])
|
||||
|
|
Loading…
Add table
Reference in a new issue