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

Correct async lightning-background-processor exit check docs #1843

Merged

Conversation

TheBlueMatt
Copy link
Collaborator

The check to stop the background processor is true -> break, not false -> break. This simply updates the docs and leaves the code as-is.

@TheBlueMatt TheBlueMatt added this to the 0.0.113 milestone Nov 9, 2022
@codecov-commenter
Copy link

codecov-commenter commented Nov 9, 2022

Codecov Report

Base: 90.74% // Head: 90.71% // Decreases project coverage by -0.03% ⚠️

Coverage data is based on head (71739db) compared to base (3b2f694).
Patch has no changes to coverable lines.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1843      +/-   ##
==========================================
- Coverage   90.74%   90.71%   -0.04%     
==========================================
  Files          87       87              
  Lines       47364    47364              
  Branches    47364    47364              
==========================================
- Hits        42980    42965      -15     
- Misses       4384     4399      +15     
Impacted Files Coverage Δ
lightning-background-processor/src/lib.rs 96.23% <ø> (ø)
lightning/src/util/events.rs 38.13% <0.00%> (-0.27%) ⬇️
lightning/src/ln/functional_tests.rs 96.88% <0.00%> (-0.20%) ⬇️
lightning/src/ln/monitor_tests.rs 99.44% <0.00%> (-0.12%) ⬇️
lightning/src/ln/channelmanager.rs 85.16% <0.00%> (-0.03%) ⬇️
lightning/src/chain/channelmonitor.rs 90.70% <0.00%> (+0.05%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

lightning-background-processor/src/lib.rs Outdated Show resolved Hide resolved
let mut should_continue = true;
let mut should_break = true;
Copy link
Contributor

Choose a reason for hiding this comment

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

Perhaps we should be explicit and use an enum to avoid confusion.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I'm not sure we're gonna have this bug twice :). As with this case, I think a user who implements it wrong should see pretty quick that its wrong, though I agree in the future we may consider doing enums more aggressively rather than bools.

wpaulino
wpaulino previously approved these changes Nov 9, 2022
The check to stop the background processor is true -> break, not
false -> break. This simply updates the docs and leaves the code
as-is.
@TheBlueMatt TheBlueMatt merged commit 384c4dc into lightningdevkit:main Nov 10, 2022
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