contractcourt: create breachResolver if BreachResolution present

Also transitions to the proper state based on if this is a legacy
breach in the channel arbitrator or a modern breach with a resolver.
This commit is contained in:
eugene
2022-01-13 14:55:55 -05:00
parent af03c8cb46
commit b7407882ac
2 changed files with 122 additions and 28 deletions

View File

@@ -147,7 +147,7 @@ const (
// | | |
// | | |-> StateCommitmentBroadcasted: chain/user trigger
// | | |
// | | |-> StateContractClosed: local/remote close trigger
// | | |-> StateContractClosed: local/remote/breach close trigger
// | | | |
// | | | |-> StateWaitingFullResolution: contract resolutions not empty
// | | | | |
@@ -157,9 +157,9 @@ const (
// | | | |
// | | | |-> StateFullyResolved: contract resolutions empty
// | | |
// | | |-> StateFullyResolved: coop/breach close trigger
// | | |-> StateFullyResolved: coop/breach(legacy) close trigger
// | |
// | |-> StateContractClosed: local/remote close trigger
// | |-> StateContractClosed: local/remote/breach close trigger
// | | |
// | | |-> StateWaitingFullResolution: contract resolutions not empty
// | | | |
@@ -169,11 +169,11 @@ const (
// | | |
// | | |-> StateFullyResolved: contract resolutions empty
// | |
// | |-> StateFullyResolved: coop/breach close trigger
// | |-> StateFullyResolved: coop/breach(legacy) close trigger
// |
// |-> StateContractClosed: local/remote close trigger
// |-> StateContractClosed: local/remote/breach close trigger
// | |
// | |-> StateWaitingFullResolution: contract resolutions empty
// | |-> StateWaitingFullResolution: contract resolutions not empty
// | | |
// | | |-> StateWaitingFullResolution: contract resolutions not empty
// | | |
@@ -181,7 +181,7 @@ const (
// | |
// | |-> StateFullyResolved: contract resolutions empty
// |
// |-> StateFullyResolved: coop/breach close trigger
// |-> StateFullyResolved: coop/breach(legacy) close trigger
// StateDefault is the default state. In this state, no major actions
// need to be executed.