Check for new log entries since the last check.
(self)
| 76 | print("No valid certificate found in the response.") |
| 77 | |
| 78 | def check_new_logs(self): |
| 79 | """Check for new log entries since the last check.""" |
| 80 | logs = self.get_logs(count=10000) |
| 81 | print("num logs", len(logs)) |
| 82 | for log in logs: |
| 83 | print(f"log id={log['id']}") |
| 84 | if log["id"] <= (self.last_checked or 0): |
| 85 | break |
| 86 | self.check_one_log(log) |
| 87 | print("next") |
| 88 | if len(logs) > 0: |
| 89 | self.last_checked = logs[0]["id"] |
| 90 | |
| 91 | def run(self): |
| 92 | """Run the monitor loop indefinitely.""" |
no test coverage detected