Skip to content

Only notify the directory authorities that are above/below the threshold for bwauths being in sync

We have a check that tests whether our bwauth measurements are in sync which goes like this:

for authority, count in list(measurement_counts.items()):
    if count > (1.2 * average) or count < (0.8 * average):
      entries = ['%s (%s)' % (authority, count) for authority, count in list(measurement_counts.items())]
      return Issue(Runlevel.NOTICE, 'BANDWIDTH_AUTHORITIES_OUT_OF_SYNC', authorities = ', '.join(entries), to = list(measurement_counts.keys()))

So, as soon as there is one authority which is above or below the threshold all authorities get notified that the bwauths are out of sync.

I think at least @linus is expecting to only get notified if his authority is out of sync.