You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Validator log where it says attestationInclusionPercentage=1.00 correctlyVotedHeadPercentage=0.00 correctlyVotedSourcePercentage=1.00 correctlyVotedTargetPercentage=1.00 should be percentage 100% not decimal point 1.00
I am going to add this function to the mathutil: func Percent(current, maximum float64) int { percentage := float64(current) / float64(maximum) * float64(100) return int(percentage / float64(10)) }
The test shape is: func TestPercent(t *testing.T) { tests := []struct { a uint64 b uint64 result uint64 }{ { a: 20, b: 40, result: 50, } } for _, tt := range tests { if tt.result != mathutil.Percent(tt.a, tt.b) { t.Fatalf("Percent(%d) = %d, wanted: %d", tt.a, mathutil.Percent(tt.a, tt.b), tt.result) } } }
Validator log where it says
attestationInclusionPercentage=1.00 correctlyVotedHeadPercentage=0.00 correctlyVotedSourcePercentage=1.00 correctlyVotedTargetPercentage=1.00
should be percentage100%
not decimal point1.00
Opening this issue to update the log to percentage presentation.
Here is the line:
https://github.com/prysmaticlabs/prysm/blob/master/validator/client/validator_metrics.go#L115
The text was updated successfully, but these errors were encountered: