Skip to content

Helm 4: Emits "unable to find exact version" when a version range was specified #31757

Description

@armingerten

What happened?

This is related to #31548 / #31549 / #31254.

When running commands like helm show chart or helm template using a version range, a warning is emitted that suggests that no exact version can be found:

helm show chart brigade/brigade --version '^1'
evel=WARN msg="unable to find exact version requested; falling back to closest available version" chart=brigade requested=^1 selected=1.10.0
apiVersion: v1
...
description: Brigade provides event-driven scripting of Kubernetes pipelines.
name: brigade
version: 1.10.0

What did you expect to happen?

In case a version range was specified (i.e. the --version parameter was set to ^1 or ~1.10), no warning should be emitted and a version matching the criteria is used as described by the --version flag description:

  --version string             specify a version constraint for the chart version to use. This constraint can be a specific tag (e.g. 1.1.1) or it may reference a valid range (e.g. ^2.0.0). If this is not specified, the latest version is used

How can we reproduce it (as minimally and precisely as possible)?

  1. helm repo add brigade https://brigadecore.github.io/charts
  2. helm repo update
  3. helm show chart brigade/brigade --version ^1

Helm version

Details
$ helm version
version.BuildInfo{Version:"v4.0.5", GitCommit:"1b6053d48b51673c5581973f5ae7e104f627fcf5", GitTreeState:"clean", GoVersion:"go1.25.5", KubeClientVersion:"v1.34"}

Kubernetes version

Details
$ kubectl version
Client Version: v1.32.7
Kustomize Version: v5.5.0
Server Version: v1.33.6

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions