Skip to content

fix: preserve version prefix in deploy.sh for helm install#92

Merged
yuanchen8911 merged 3 commits intoNVIDIA:mainfrom
yuanchen8911:fix/preserve-version-prefix
Feb 11, 2026
Merged

fix: preserve version prefix in deploy.sh for helm install#92
yuanchen8911 merged 3 commits intoNVIDIA:mainfrom
yuanchen8911:fix/preserve-version-prefix

Conversation

@yuanchen8911
Copy link
Contributor

Summary

Fix Helm version warning when deploy.sh strips the v prefix from chart versions.

Problem

The normalizeVersion() function strips the v prefix from version strings for all uses, including helm install --version. This causes Helm to log warnings:

WARN unable to find exact version requested; falling back to closest
     available version chart=gpu-operator requested=25.10.1 selected=v25.10.1

Fix

Split version into two fields in ComponentData:

  • Version: Original string (preserves v prefix) — used in deploy.sh for helm install --version
  • ChartVersion: Normalized string (no v prefix) — used in manifest chart metadata labels

Also updated the test manifest template to use {{ .Chart.Version }} matching the pattern used by real manifests.

Test plan

  • make test passes
  • TestGenerate_WithManifests passes with correct chart label (gpu-operator-25.3.3)
  • Generated deploy.sh preserves v prefix for --version flag

@yuanchen8911 yuanchen8911 requested a review from a team as a code owner February 11, 2026 01:49
The deploy.sh template was stripping the 'v' prefix from chart versions
via normalizeVersion(), causing Helm to log warnings like:

  unable to find exact version requested; falling back to closest
  available version chart=gpu-operator requested=25.10.1 selected=v25.10.1

Split the version into two fields:
- Version: original string (preserves 'v' prefix) for helm install --version
- ChartVersion: normalized string (no 'v' prefix) for chart metadata labels

Also update the test manifest template to use {{ .Chart.Version }}
matching the pattern used by real manifests in the codebase.

Signed-off-by: Yuan Chen <yuanchen97@gmail.com>
@yuanchen8911 yuanchen8911 force-pushed the fix/preserve-version-prefix branch from c26cbc9 to 2d58c7f Compare February 11, 2026 05:44
Copy link
Member

@mchmarny mchmarny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CI doesn't check much now beyond CUJ1, so just make sure this handles the empty versions correctly

Copy link
Member

@mchmarny mchmarny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@yuanchen8911 yuanchen8911 merged commit dd5ddbc into NVIDIA:main Feb 11, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants