Skip to content

Clarify the error message when we disconnect a peer #2209

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

Merged

Conversation

TheBlueMatt
Copy link
Collaborator

We very regularly receive confusion over the super generic "Peer sent invalid data or we decided to disconnect due to a protocol error" message, which doesn't say very much. Usually, we end up disconnecting because we have a duplicate connection with a peer, which doesn't merit such a scary message.

Instead, here we clarify the error message to just refer to the fact that we're disconnecting, and note that its usually a dup connection in a parenthetical.

We very regularly receive confusion over the super generic
"Peer sent invalid data or we decided to disconnect due to a
protocol error" message, which doesn't say very much. Usually, we
end up disconnecting because we have a duplicate connection with a
peer, which doesn't merit such a scary message.

Instead, here we clarify the error message to just refer to the
fact that we're disconnecting, and note that its usually a dup
connection in a parenthetical.
It currently reads "disconnected from peer which hasn't completed
handshake due to ping timeout", which is confusing.

Instead, it will now read "disconnected from peer which hasn't
completed handshake due to ping/handshake timeout"
@codecov-commenter
Copy link

codecov-commenter commented Apr 21, 2023

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (9d5adfc) 91.50% compared to head (49a3662) 91.50%.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2209   +/-   ##
=======================================
  Coverage   91.50%   91.50%           
=======================================
  Files         104      104           
  Lines       51176    51176           
  Branches    51176    51176           
=======================================
+ Hits        46829    46831    +2     
+ Misses       4347     4345    -2     
Impacted Files Coverage Δ
lightning/src/ln/peer_handler.rs 62.57% <100.00%> (ø)

... and 2 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.

@TheBlueMatt TheBlueMatt merged commit 8f4bd19 into lightningdevkit:main Apr 24, 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