[fix] issue #694: CI failure bot stays silent when no actual failures found#697
[fix] issue #694: CI failure bot stays silent when no actual failures found#697BHARATH0153 wants to merge 6 commits into
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughThis PR prevents the CI failure bot from posting "No Failures Found" comments by adding early-exit guards in the Python analysis script (skip when processed Sequence Diagram(s)sequenceDiagram
participant Workflow
participant analyze_failure_py as analyze_failure.py
participant failed_logs as failed_logs.txt
participant LLM
Workflow->>analyze_failure_py: invoke analysis (with failed_logs.txt, error_log)
analyze_failure_py->>failed_logs: read and process error_log
analyze_failure_py-->>analyze_failure_py: early return if error_log empty/whitespace
alt tests_failed == false and transient_only == false
analyze_failure_py->>failed_logs: re-open and scan failed_logs.txt for "no failures/logs unavailable/could not fetch"
failed_logs-->>analyze_failure_py: pattern matched?
analyze_failure_py-->>Workflow: print notice and return (skip LLM) if matched
else
analyze_failure_py->>LLM: invoke LLM analysis
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested reviewers
Caution Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional.
❌ Failed checks (1 error)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…s detected Two-layer guard: skip analysis in analyze_failure.py when logs contain no error markers, and skip the Post Comment step in reusable-bot-ci-failure.yml when no errors are found. Closes openwisp#694
ac968a1 to
20ed4ce
Compare
|
@nemesifier please review whenever possible thanks! |
This reverts commit 4c80968.
fee1dac to
beea942
Compare
|
The CI is failing due to transient infrastructure issues (not related to your code). I have restarted the failed jobs automatically (1/3). |
|
The CI is failing due to transient infrastructure issues (not related to your code). I have restarted the failed jobs automatically (2/3). |
44734ac to
f607473
Compare
Checklist
Closes #694
changes
Used solution 1 from the issue description — the bot now stays silent when there are no actual failures to report.
Two changes:
##[error]markers or only contain boilerplate like "No failed jobs found"##[error]in the logs before posting. If nothing found, no comment.