Compare commits
1 Commits
main
...
check-inst
Author | SHA1 | Date | |
---|---|---|---|
66bbb010e5 |
|
@ -132,6 +132,9 @@ def filter_checks_on_frequency(
|
||||||
make_check_time_path(location_config, borg_repository_id, check)
|
make_check_time_path(location_config, borg_repository_id, check)
|
||||||
)
|
)
|
||||||
if not check_time:
|
if not check_time:
|
||||||
|
logger.debug(
|
||||||
|
f"Running {check} check due to never having run before"
|
||||||
|
)
|
||||||
continue
|
continue
|
||||||
|
|
||||||
# If we've not yet reached the time when the frequency dictates we're ready for another
|
# If we've not yet reached the time when the frequency dictates we're ready for another
|
||||||
|
@ -142,6 +145,11 @@ def filter_checks_on_frequency(
|
||||||
f"Skipping {check} check due to configured frequency; {remaining} until next check"
|
f"Skipping {check} check due to configured frequency; {remaining} until next check"
|
||||||
)
|
)
|
||||||
filtered_checks.remove(check)
|
filtered_checks.remove(check)
|
||||||
|
else:
|
||||||
|
due_at = check_time + frequency_delta
|
||||||
|
logger.debug(
|
||||||
|
f"Running {check} check due to configured frequency; the last check was at {check_time} with a frequency of {check_config.get('frequency')}, so the check was due at {due_at} ({datetime.datetime.now() - due_at} ago)"
|
||||||
|
)
|
||||||
|
|
||||||
return tuple(filtered_checks)
|
return tuple(filtered_checks)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user