Some checks failed
Smoke Test / smoke (pull_request) Failing after 23s
Architecture Lint / Linter Tests (pull_request) Successful in 26s
Validate Config / YAML Lint (pull_request) Failing after 17s
Validate Config / JSON Validate (pull_request) Successful in 20s
Validate Config / Python Syntax & Import Check (pull_request) Failing after 55s
Validate Config / Python Test Suite (pull_request) Has been skipped
Validate Config / Shell Script Lint (pull_request) Failing after 1m0s
Validate Config / Cron Syntax Check (pull_request) Successful in 11s
Validate Config / Deploy Script Dry Run (pull_request) Successful in 12s
Validate Config / Playbook Schema Validation (pull_request) Successful in 23s
Architecture Lint / Lint Repository (pull_request) Failing after 19s
PR Checklist / pr-checklist (pull_request) Successful in 3m0s
Split the audit into an importable cron_audit_662 module plus a CLI wrapper, classify recent systemic failures by error signature instead of age alone, and include enough metadata for issue filing and delivery-failure reporting. Add regression tests for import-path loading, systemic vs transient classification, and issue body generation.
23 lines
833 B
Python
Executable File
23 lines
833 B
Python
Executable File
#!/usr/bin/env python3
|
|
"""CI: Validate cron fleet health. Exit 1 on systemic failures."""
|
|
|
|
import sys
|
|
from pathlib import Path
|
|
sys.path.insert(0, str(Path(__file__).parent))
|
|
from cron_audit_662 import audit_fleet, load_cron_state, load_crontab_backups
|
|
|
|
def main():
|
|
hermes = load_cron_state()
|
|
crontabs = load_crontab_backups(Path(__file__).parent.parent / "cron" / "vps")
|
|
report = audit_fleet(hermes, crontabs)
|
|
print(f"Cron Audit CI: {report['total_jobs']} jobs — H:{report['summary']['healthy']} T:{report['summary']['transient_errors']} S:{report['summary']['systemic_failures']}")
|
|
if report["systemic_jobs"]:
|
|
for j in report["systemic_jobs"]:
|
|
print(f" FAIL: {j['name']} — {j['reason']}")
|
|
sys.exit(1)
|
|
print("CI PASSED")
|
|
sys.exit(0)
|
|
|
|
if __name__ == "__main__":
|
|
main()
|