-
Notifications
You must be signed in to change notification settings - Fork 215
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 by Bors] - malfeasance2: update GRPC API #6557
Conversation
Codecov ReportAttention: Patch coverage is
✅ All tests successful. No failed tests found. Additional details and impacted files@@ Coverage Diff @@
## develop #6557 +/- ##
=========================================
- Coverage 79.8% 79.7% -0.1%
=========================================
Files 354 355 +1
Lines 47015 47135 +120
=========================================
+ Hits 37534 37603 +69
- Misses 7351 7390 +39
- Partials 2130 2142 +12 ☔ View full report in Codecov by Sentry. |
bors merge |
## Motivation This updates the malfeasance v2alpha1 endpoints to be able to return both legacy and v2 malfeasance proofs.
Possibly overlooked before approving -- are we really using |
Yes we do - go-spacemesh/api/grpcserver/v2alpha1/malfeasance_test.go Lines 144 to 152 in 0cb2cfa
|
Ok I see, thanks. |
Build failed: |
Flaky test: #6113 bors merge |
## Motivation This updates the malfeasance v2alpha1 endpoints to be able to return both legacy and v2 malfeasance proofs.
Pull request successfully merged into develop. Build succeeded: |
## Motivation Followup for #6557. Now malfeasance2 proofs are actually fetched from the DB and metadata for them returned.
## Motivation Followup for #6557. Now malfeasance2 proofs are actually fetched from the DB and metadata for them returned.
## Motivation Followup for #6557. Now malfeasance2 proofs are actually fetched from the DB and metadata for them returned.
Motivation
This updates the malfeasance v2alpha1 endpoints to be able to return both legacy and v2 malfeasance proofs.
Description
I changed the malfeasance events to not include the encoded proof any more instead they only report which identity was detected to be malicious and expect the receiver of the event to fetch a proof from the state DB if needed (or call
Info
on one of the two malfeasance handlers to get information about the malicious behavior of the given identity)GRPC tests have been updated to check if both v1 and v2 malfeasance proofs are handled correctly.
The
malfeasance2.Handler
in this PR always returnssql.ErrNotFound
to keep the PR size manageable. The full implementation of themalfeasance2.Handler
can be found in #6307Test Plan
existing tests have been updated and new tests were added for changed / added functionality
TODO