fix validator progress counter

if custody is based on the requirements of underlying individual
validators, we can get detailed data on how many validated.
Otherwise, we can only use the weighted average.

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
This commit is contained in:
Csaba Kiraly 2024-03-01 10:46:24 +01:00
parent a634aa07e0
commit 911ee6b6e4
No known key found for this signature in database
GPG Key ID: 0FE274EE8C95166E
1 changed files with 9 additions and 1 deletions

View File

@ -290,10 +290,18 @@ class Simulator:
cnD1 = "Dup class1 mean"
cnD2 = "Dup class2 mean"
# if custody is based on the requirements of underlying individual
# validators, we can get detailed data on how many validated.
# Otherwise, we can only use the weighted average.
if self.config.validatorBasedCustody:
cnVv = validatorProgress
else:
cnVv = validatorAllProgress
progressVector.append({
cnS:sampleProgress,
cnN:nodeProgress,
cnV:validatorProgress,
cnV:cnVv,
cnT0: trafficStats[0]["Tx"]["mean"],
cnT1: trafficStats[1]["Tx"]["mean"],
cnT2: trafficStats[2]["Tx"]["mean"],