← Back to Pull requests

fix: return evaluation errors from processAllNodesForRule #497

Closed
unknown closed this pull request without merging on Nov 09, 2026 19:11 UTC
View on GitHub
unknown unknown commented on Nov 05, 2026 18:13 UTC
Author

<!-- Thanks for sending a pull request! Here are some tips for you:

  • If this is your first time, please read our contributor guidelines: https://git.k8s.io/community/contributors/guide#your-first-contribution and developer guide https://git.k8s.io/community/contributors/devel/development.md#development-guide

  • If you want faster PR reviews, read how: https://git.k8s.io/community/contributors/guide/pull-requests.md#best-practices-for-faster-reviews

  • If the PR is unfinished, see how to mark it: https://git.k8s.io/community/contributors/guide/pull-requests.md#marking-unfinished-pull-requests

  • -->

    Description


    processAllNodesForRule saves node failures to status but always returns nil, so failed nodes are never retried.

    This returns the errors with errors.Join, like processNodeAgainstAllRules does. Reconcile still saves status before returning the error.

    Continues #237 by @dorodb-web22.
    <!-- Brief description of changes -->

    Related Issue


    Fixes #234
    <!--
    Automatically closes linked issue when PR is merged.
    Usage: Fixes #<issue number>, or Fixes (paste link of issue).

    Fixes #

    or

    None
    -->

    Type of Change


    /kind bug
    <!--
    Add one of the following kinds:

    /kind cleanup
    /kind documentation
    /kind feature
    /kind design

    Optionally add one or more of the following kinds if applicable:
    /kind api-change
    /kind deprecation
    /kind failing-test
    /kind flake
    /kind regression
    -->

    Testing


  • make test passes.

  • Updated the test that expected no error on a failed node.

  • Added a test that checks Reconcile returns the error and saves FailedNodes.

  • <!-- How was this tested? -->

    Checklist


  • [X] make test passes

  • [X] make lint passes
  • Does this PR introduce a user-facing change?

    <!--
    If no, just write "NONE" in the release-note block below.
    If yes, a release note is required:
    1. Enter your extended release note in the block below. If the PR requires additional action from users switching to the new release, include the string "action required".
    2. Add 'Doc #(issue)' after the block if there is a follow up
    For more information on release notes see: https://git.k8s.io/community/contributors/guide/release-notes.md
    -->

    ``release-note
    NodeReadinessRule reconciliation now retries when evaluating a node fails, instead of silently dropping the error.
    ``
    Doc #(issue)

    Generative AI Usage Disclosure


    <!--
    If you used AI tools in preparing this PR, please disclose and how they were used.

    Using AI tools to help write your PR is acceptable, but as the author, you are responsible for understanding every change in your contribution.

    Please write the PR description in your words. Do not submit AI-generated summary and analysis and do not leave the first review of AI generated changes to the reviewers, please verify the changes (code review, local testing, etc.) before submitting your PR.

    For more details please review guidelines on responsible Generative AI usage:
    https://www.linuxfoundation.org/legal/generative-ai
    https://www.kubernetes.dev/docs/guide/pull-requests/#ai-guidance

    -->

  • [X] No AI tools were used

  • AI tools were used (complete below)
  • How they were used:*
    <!-- Describe what the AI helped with (e.g., code generation, refactoring, documentation, tests) and which parts of the PR were affected -->

    Diff: 412 lines (+309 / -103) across 5 files Reviewer: ajaysundark Review duration: 5818m
    All Vouch review confidence checks passed
    Residual risk 0.18 = Change Risk (0.45) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.45 · 412 lines diff across 5 files
    0.45
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.360
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #497"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 44.9% (MEDIUM) · Higher = larger blast radius
    44.9%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 17.7% · Safe to merge
    17.7%