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

fix: remove gatewayd reconnect expects #2173

Merged
merged 1 commit into from
Apr 10, 2023

Conversation

m1sterc001guy
Copy link
Contributor

When actors in gatewayd are processing htlcs, they wait on two futures (one is a signal that the thread should shutdown, the other is the htlc sent from the lightning node).

There is a race condition currently where we try to send a "shutdown" signal over a channel that then returns an error. This can happen during shutdown, where the webserver and the connection to the lightning node shutdown at the same time. Currently, we have some expects that will crash gatewayd if it can't send over the channel. This PR changes it to remove the expects so that gatewayd doesn't crash in this case.

@m1sterc001guy m1sterc001guy requested a review from a team as a code owner April 7, 2023 18:49
@codecov
Copy link

codecov bot commented Apr 7, 2023

Codecov Report

Patch coverage has no change and project coverage change: -0.16 ⚠️

Comparison is base (51d736d) 60.20% compared to head (b80996a) 60.05%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2173       /-   ##
==========================================
- Coverage   60.20%   60.05%   -0.16%     
==========================================
  Files         152      152              
  Lines       31046    31054        8     
==========================================
- Hits        18692    18649      -43     
- Misses      12354    12405       51     
Impacted Files Coverage Δ
gateway/ln-gateway/src/actor.rs 44.06% <0.00%> (-1.13%) ⬇️

... and 8 files with indirect coverage changes

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 in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

gateway/ln-gateway/src/actor.rs Outdated Show resolved Hide resolved
@m1sterc001guy m1sterc001guy requested a review from a team as a code owner April 10, 2023 14:44
@maan2003 maan2003 mentioned this pull request Apr 10, 2023
Copy link
Contributor

@mxz42 mxz42 left a comment

Choose a reason for hiding this comment

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

👍 CI build "fails" though

@dpc dpc merged commit 7bad9c1 into fedimint:master Apr 10, 2023
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