Skip to content

contractcourt: only supplement resolvers if channel has historical state#6003

Closed
Roasbeef wants to merge 2 commits intolightningnetwork:masterfrom
Roasbeef:historical-resolver-state
Closed

contractcourt: only supplement resolvers if channel has historical state#6003
Roasbeef wants to merge 2 commits intolightningnetwork:masterfrom
Roasbeef:historical-resolver-state

Conversation

@Roasbeef
Copy link
Copy Markdown
Member

In this commit, we fix a bug that would cause newly updated nodes to be
unable to start up, if they have an older channel that was closed before
we started to store all the historical state for each channel.

The issue is that we started to write the complete state to disk, but
newer channels don't have it, so when we try to supplement the
resolvers, we run into this error.

Ultimately, we only need this new supplemented information for script
enforcement channels. Ideally we would instead check the channel type
there instead, but it doesn't appear to be available in this context as
is, without further changes.

Fixes #6001.

@Roasbeef Roasbeef added this to the v0.14.1 milestone Nov 18, 2021
@Crypt-iQ
Copy link
Copy Markdown
Collaborator

but newer channels don't have it

Could change commit message to say older channels don't have it

@Roasbeef
Copy link
Copy Markdown
Member Author

cc @robtex

@Roasbeef Roasbeef force-pushed the historical-resolver-state branch from d84ad7f to 608e0c3 Compare November 18, 2021 21:40
Copy link
Copy Markdown
Collaborator

@Crypt-iQ Crypt-iQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🌮

Copy link
Copy Markdown
Collaborator

@Crypt-iQ Crypt-iQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

think the itests are flakes

@Roasbeef
Copy link
Copy Markdown
Member Author

Confirmed from a user so far this resolved the issue 👍

In this commit, we fix a bug that would cause newly updated nodes to be
unable to start up, if they have an older channel that was closed before
we started to store all the historical state for each channel.

The issue is that we started to write the complete state to disk, but
newer channels don't have it, so when we try to supplement the
resolvers, we run into this error.

Ultimately, we only need this new supplemented information for script
enforcement channels. Ideally we would instead check the channel type
there instead, but it doesn't appear to be available in this context as
is, without further changes.

Fixes lightningnetwork#6001.
@guggero
Copy link
Copy Markdown
Collaborator

guggero commented Nov 24, 2021

Replaced by #6026.

@guggero guggero closed this Nov 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"channel not found" causing shutdown after upgrade to 0.14

3 participants