ObolNetwork / charon

Charon (pronounced 'kharon') is a Proof of Stake Ethereum Distributed Validator Client
https://docs.obol.tech/
Other
166 stars 78 forks source link

core/validatorapi: return requested validators #3123

Closed gsora closed 4 weeks ago

gsora commented 4 weeks ago

Instead of always returning the full cache on Validators() requests, only return whatever was requested originally.

Still check cache first, then upstream BN, then if anything comes up return to the caller.

Harden tests to check for this behavior.

Log a debug message when refreshing the validator cache.

Make sure to always refresh the validator cache as soon as the first observed epoch begins, then fall back to the standard refresh pattern (once every epoch).

category: bug ticket: none

codecov[bot] commented 4 weeks ago

Codecov Report

Attention: Patch coverage is 35.71429% with 27 lines in your changes missing coverage. Please review.

Project coverage is 56.78%. Comparing base (43979af) to head (7e4a750).

Files Patch % Lines
app/app.go 0.00% 27 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #3123 +/- ## ========================================== - Coverage 56.82% 56.78% -0.04% ========================================== Files 208 208 Lines 29276 29305 +29 ========================================== + Hits 16637 16642 +5 - Misses 10801 10828 +27 + Partials 1838 1835 -3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

sonarcloud[bot] commented 4 weeks ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud