Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add persistence test for htlc in the LocalRemoved state #3645

Merged

Conversation

joostjager
Copy link
Contributor

@joostjager joostjager commented Mar 5, 2025

Increase coverage and prepare for attributable failures which are going to extend the update_fail_htlc message with an additional field that needs to be persisted as well (#3611)

@ldk-reviews-bot
Copy link

ldk-reviews-bot commented Mar 5, 2025

👋 Thanks for assigning @valentinewallace as a reviewer!
I'll wait for their review and will help manage the review process.
Once they submit their review, I'll check if a second reviewer would be helpful.

Copy link

codecov bot commented Mar 5, 2025

Codecov Report

Attention: Patch coverage is 98.64865% with 1 line in your changes missing coverage. Please review.

Project coverage is 90.25%. Comparing base (eaeed77) to head (96b172e).
Report is 48 commits behind head on main.

Files with missing lines Patch % Lines
lightning/src/ln/channelmanager.rs 98.64% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3645      +/-   ##
==========================================
+ Coverage   89.16%   90.25%   +1.08%     
==========================================
  Files         152      155       +3     
  Lines      118791   127106    +8315     
  Branches   118791   127106    +8315     
==========================================
+ Hits       105921   114715    +8794     
+ Misses      10312     9940     -372     
+ Partials     2558     2451     -107     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@valentinewallace valentinewallace left a comment

Choose a reason for hiding this comment

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

Looks good!

@ldk-reviews-bot
Copy link

👋 The first review has been submitted!

Do you think this PR is ready for a second reviewer? If so, click here to assign a second reviewer.

@joostjager joostjager force-pushed the test-failed-htlc-persistence branch 2 times, most recently from 4d1462b to d8754e2 Compare March 6, 2025 08:33
@joostjager joostjager force-pushed the test-failed-htlc-persistence branch 2 times, most recently from dea1c86 to 9fc56ac Compare March 6, 2025 08:43
@joostjager joostjager force-pushed the test-failed-htlc-persistence branch from 9fc56ac to 42db0df Compare March 6, 2025 08:45
Increase coverage and prepare for attributable failures which are going
to extend the update_fail_htlc message with an additional field that
needs to be persisted as well.
@joostjager joostjager force-pushed the test-failed-htlc-persistence branch from 42db0df to 25a749e Compare March 6, 2025 14:34
Copy link
Contributor

@valentinewallace valentinewallace left a comment

Choose a reason for hiding this comment

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

Will land after CI passes since this just adds a test

Copy link
Contributor

@carlaKC carlaKC left a comment

Choose a reason for hiding this comment

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

Not very familiar with all the helper functions used here but test lgtm from a LN message flow standpoint 👌

@joostjager
Copy link
Contributor Author

Not very familiar with all the helper functions used here but test lgtm from a LN message flow standpoint 👌

Tests are indeed quite different in LDK compared to LND. There is a lot more manual message passing that needs to happen. But the upside is that the test suite runs incredibly fast.

Thanks for taking a look!

@joostjager joostjager merged commit 3a5f428 into lightningdevkit:main Mar 6, 2025
26 of 27 checks passed
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.

4 participants