← Back to Pull requests

Fix Kubernetes version string handling by stripping metadata #623

Closed
unknown closed this pull request without merging on Nov 18, 2024 04:22 UTC
View on GitHub
unknown unknown commented on Nov 16, 2024 05:02 UTC
Author

What type of PR is this?
/kind bug

<!--
Add one of the following kinds:
/kind bug
/kind cleanup
/kind deprecation
/kind design
/kind documentation
/kind failing-test
/kind feature
/kind flake
-->

What this PR does / why we need it:
This PR fixes an issue where Kubernetes version strings with additional metadata (e.g., +k3s1) caused problems in dynamically generated image tags. The new strippedKubeVersion function removes the part after the + in the Kubernetes version string, ensuring consistent and predictable image tagging.

Which issue(s) this PR fixes:
Fixes #621

Special notes for your reviewer:
@archlitchi
@wawa0210

Does this PR introduce a user-facing change?:
Yes, this PR restores compatibility for specifying certain parameters during helm install/upgrade.

After version 2.4.1, users were unable to specify parameters like scheduler.kubeScheduler.tag (scheduler image version), devicePlugin.deviceSplitCount, devicePlugin.deviceMemoryScaling, and devicePlugin.deviceCoreScaling directly during Helm operations.

With this PR merged:

  • Users can now specify the scheduler image version using scheduler.kubeScheduler.tag during helm install or helm upgrade. If the parameter is not provided, the image version will continue to be auto-generated based on the Kubernetes version.

  • Parameters like deviceSplitCount, deviceMemoryScaling, and deviceCoreScaling are also restored for direct specification during Helm operations.
  • Diff: 190 lines (+142 / -48) across 2 files Reviewer: wawa0210 Review duration: 2839m
    All Vouch review confidence checks passed
    Residual risk 0.27 = Change Risk (0.59) × (1 − Review Confidence (0.54)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.59 · 190 lines diff across 2 files
    0.59
    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%
    54%
    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.314
    Shallow Review Depth shallow_review_depth
    0.289
    Sensitive Paths sensitive_paths
    0.059
    Real PR Conversation Timeline
    1 comments
    "Review active on #623"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 54.2% reviewed sensitive_module
    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: 59.1% (MEDIUM) · Higher = larger blast radius
    59.1%
    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: 54.2% · Lower = rushed or shallow review
    54.2%
    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: 27% · Safe to merge
    27%