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
feat: add down-scoring for metadata ssz size error #6366
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## unstable #6366 +/- ##
=========================================
Coverage 60.14% 60.14%
=========================================
Files 407 407
Lines 46486 46490 +4
Branches 1545 1545
=========================================
+ Hits 27957 27960 +3
- Misses 18497 18498 +1
Partials 32 32 |
Performance Report✔️ no performance regression detected Full benchmark results
|
@@ -31,6 +31,8 @@ export enum RequestErrorCode { | |||
RESP_TIMEOUT = "REQUEST_ERROR_RESP_TIMEOUT", | |||
/** Request rate limited */ | |||
REQUEST_RATE_LIMITED = "REQUEST_ERROR_RATE_LIMITED", | |||
/** */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is this left empty, sounds useful to know later why it was introduced without looking at the PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes please do a follow up PR @matthewkeil
🎉 This PR is included in v1.16.0 🎉 |
Motivation
Downscore peers that send invalid metadata. Usually comes from
Unknown
client so possibly minority client in development that has bugs.Resolves #6315
Description
Add
RequestErrorCode.SSZ_OVER_MAX_SIZE
Apply
PeerAction.LowToleranceError
to limit to 5 instances before disconnect.