python actions have no attribute 'consistencyCheck' by default;

closes gh-3214
pull/2296/merge
sebres 2022-02-08 19:57:40 +01:00
parent 810386a265
commit 8013cf0b90
1 changed files with 3 additions and 2 deletions

View File

@ -513,9 +513,10 @@ class Actions(JailThread, Mapping):
if bTicket.banEpoch == self.banEpoch and diftm > 3:
# avoid too often checks:
if not rebanacts and MyTime.time() > self.__lastConsistencyCheckTM + 3:
for action in self._actions.itervalues():
action.consistencyCheck()
self.__lastConsistencyCheckTM = MyTime.time()
for action in self._actions.itervalues():
if hasattr(action, 'consistencyCheck'):
action.consistencyCheck()
# check epoch in order to reban it:
if bTicket.banEpoch < self.banEpoch:
if not rebanacts: rebanacts = dict(