Repository: helm/helm
Pull request #12332 (2023-08-24 22:06:13)

chore(deps): bump transparencylog/github-releases-asset-transparency-verify-action from 10 to 11
Bumps [transparencylog/github-releases-asset-transparency-verify-action](https://github.com/transparencylog/github-releases-asset-transparency-verify-action) from 10 to 11.
<details>
<summary>Commits</summary>
<ul>
<li><a href="https://github.com/transparencylog/publish-releases-asset-transparency-action/commit/c77874b4514ae4003994ece9582675195fe012e2"><code>c77874b</code></a> main: add os.Exit(1) on failed</li>
<li>See full diff in <a href="https://github.com/transparencylog/github-releases-asset-transparency-verify-action/compare/v10...v11">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=transparencylog/github-releases-asset-transparency-verify-action&package-manager=github_actions&previous-version=10&new-version=11)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)


</details>


Patch:
diff --git a/.github/workflows/asset-transparency.yaml b/.github/workflows/asset-transparency.yaml
index 7edbea2b0..ff58d1a5f 100644
--- a/.github/workflows/asset-transparency.yaml
+++ b/.github/workflows/asset-transparency.yaml
@@ -11,7 +11,7 @@ jobs:
     steps:
     - name: Gather URLs from GitHub release and publish
       id: asset-transparency
-      uses: transparencylog/github-releases-asset-transparency-verify-action@v10
+      uses: transparencylog/github-releases-asset-transparency-verify-action@c77874b4514ae4003994ece9582675195fe012e2 # v11
     - name: List verified and published URLs
       run: echo "Verified URLs ${{ steps.asset-transparency.outputs.verified }}"
     - name: List failed URLs
diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml
index 6ffc11596..09231cb97 100644
--- a/.github/workflows/codeql-analysis.yml
+++ b/.github/workflows/codeql-analysis.yml
@@ -35,11 +35,11 @@ jobs:
 
     steps:
     - name: Checkout repository
-      uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # pin@v3.6.0
+      uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # pin@v3.5.3
 
     # Initializes the CodeQL tools for scanning.
     - name: Initialize CodeQL
-      uses: github/codeql-action/init@00e563ead9f72a8461b24876bee2d0c2e8bd2ee8 # pinv2.21.5
+      uses: github/codeql-action/init@a09933a12a80f87b87005513f0abb1494c27a716 # pinv2.21.4
       with:
         languages: ${{ matrix.language }}
         # If you wish to specify custom queries, you can do so here or in a config file.
@@ -50,7 +50,7 @@ jobs:
     # Autobuild attempts to build any compiled languages  (C/C++, C#, or Java).
     # If this step fails, then you should remove it and run the build manually (see below)
     - name: Autobuild
-      uses: github/codeql-action/autobuild@00e563ead9f72a8461b24876bee2d0c2e8bd2ee8 # pinv2.21.5
+      uses: github/codeql-action/autobuild@a09933a12a80f87b87005513f0abb1494c27a716 # pinv2.21.4
 
     # ℹ️ Command-line programs to run using the OS shell.
     # 📚 https://git.io/JvXDl
@@ -64,4 +64,4 @@ jobs:
     #   make release
 
     - name: Perform CodeQL Analysis
-      uses: github/codeql-action/analyze@00e563ead9f72a8461b24876bee2d0c2e8bd2ee8 # pinv2.21.5
+      uses: github/codeql-action/analyze@a09933a12a80f87b87005513f0abb1494c27a716 # pinv2.21.4
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 055d0eaa0..1e2d7b223 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -18,7 +18,7 @@ jobs:
     runs-on: ubuntu-latest
     steps:
       - name: Checkout source code
-        uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # pin@v3.6.0
+        uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # pin@v3.5.3
 
       - name: Setup Go
         uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # pin@4.1.0
@@ -49,7 +49,7 @@ jobs:
     if: github.ref == 'refs/heads/main'
     steps:
       - name: Checkout source code
-        uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # pin@v3.6.0
+        uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # pin@v3.5.3
 
       - name: Setup Go
         uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # pin@4.1.0
diff --git a/cmd/helm/rollback.go b/cmd/helm/rollback.go
index 7de98e404..ea4b75cb1 100644
--- a/cmd/helm/rollback.go
+++ b/cmd/helm/rollback.go
@@ -32,8 +32,8 @@ const rollbackDesc = `
 This command rolls back a release to a previous revision.
 
 The first argument of the rollback command is the name of a release, and the
-second is a revision (version) number. If this argument is omitted or set to
-0, it will roll back to the previous release.
+second is a revision (version) number. If this argument is omitted, it will
+roll back to the previous release.
 
 To see revision numbers, run 'helm history RELEASE'.
 `
diff --git a/go.mod b/go.mod
index f2549557d..dbc0f5557 100644
--- a/go.mod
+++ b/go.mod
@@ -23,7 +23,7 @@ require (
 	github.com/lib/pq v1.10.9
 	github.com/mattn/go-shellwords v1.0.12
 	github.com/mitchellh/copystructure v1.2.0
-	github.com/moby/term v0.5.0
+	github.com/moby/term v0.0.0-20221205130635-1aeaba878587
 	github.com/opencontainers/image-spec v1.1.0-rc4
 	github.com/phayes/freeport v0.0.0-20220201140144-74d24b5ae9f5
 	github.com/pkg/errors v0.9.1
@@ -34,7 +34,7 @@ require (
 	github.com/stretchr/testify v1.8.4
 	github.com/xeipuuv/gojsonschema v1.2.0
 	golang.org/x/crypto v0.11.0
-	golang.org/x/term v0.11.0
+	golang.org/x/term v0.10.0
 	golang.org/x/text v0.11.0
 	k8s.io/api v0.27.3
 	k8s.io/apiextensions-apiserver v0.27.3
@@ -144,7 +144,7 @@ require (
 	golang.org/x/net v0.10.0 // indirect
 	golang.org/x/oauth2 v0.4.0 // indirect
 	golang.org/x/sync v0.1.0 // indirect
-	golang.org/x/sys v0.11.0 // indirect
+	golang.org/x/sys v0.10.0 // indirect
 	golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 // indirect
 	google.golang.org/appengine v1.6.7 // indirect
 	google.golang.org/genproto v0.0.0-20230306155012-7f2fa6fef1f4 // indirect
diff --git a/go.sum b/go.sum
index b2a44ba46..3904f4631 100644
--- a/go.sum
+++ b/go.sum
@@ -361,8 +361,8 @@ github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQ
 github.com/moby/spdystream v0.2.0 h1:cjW1zVyyoiM0T7b6UoySUFqzXMoqRckQtXwGPiBhOM8=
 github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c=
 github.com/moby/sys/mountinfo v0.6.2 h1:BzJjoreD5BMFNmD9Rus6gdd1pLuecOFPt8wC+Vygl78=
-github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0=
-github.com/moby/term v0.5.0/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y=
+github.com/moby/term v0.0.0-20221205130635-1aeaba878587 h1:HfkjXDfhgVaN5rmueG8cL8KKeFNecRCXFhaJ2qZ5SKA=
+github.com/moby/term v0.0.0-20221205130635-1aeaba878587/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y=
 github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
 github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=
 github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
@@ -648,13 +648,13 @@ golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBc
 golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.11.0 h1:eG7RXZHdqOJ1i+0lgLgCpSXAp6M3LYlAo6osgSi0xOM=
-golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.10.0 h1:SqMFp9UcQJZa+pmYuAKjd9xq1f0j5rLcDIk0mj4qAsA=
+golang.org/x/sys v0.10.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
 golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
 golang.org/x/term v0.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc=
-golang.org/x/term v0.11.0 h1:F9tnn/DA/Im8nCwm+fX+1/eBwi4qFjRT++MhtVC4ZX0=
-golang.org/x/term v0.11.0/go.mod h1:zC9APTIj3jG3FdV/Ons+XE1riIZXG4aZ4GTHiPZJPIU=
+golang.org/x/term v0.10.0 h1:3R7pNqamzBraeqj/Tj8qt1aQ2HpmlC+Cx/qL/7hn4/c=
+golang.org/x/term v0.10.0/go.mod h1:lpqdcUyK/oCiQxvxVrppt5ggO2KCZ5QblwqPnfZ6d5o=
 golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
 golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
 golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
diff --git a/pkg/action/rollback.go b/pkg/action/rollback.go
index f4ae896e3..dda8c700b 100644
--- a/pkg/action/rollback.go
+++ b/pkg/action/rollback.go
@@ -110,24 +110,6 @@ func (r *Rollback) prepareRollback(name string) (*release.Release, *release.Rele
 		previousVersion = currentRelease.Version - 1
 	}
 
-	historyReleases, err := r.cfg.Releases.History(name)
-	if err != nil {
-		return nil, nil, err
-	}
-
-	// Check if the history version to be rolled back exists
-	previousVersionExist := false
-	for _, historyRelease := range historyReleases {
-		version := historyRelease.Version
-		if previousVersion == version {
-			previousVersionExist = true
-			break
-		}
-	}
-	if !previousVersionExist {
-		return nil, nil, errors.Errorf("release has no %d version", previousVersion)
-	}
-
 	r.cfg.Log("rolling back %s (current: v%d, target: v%d)", name, currentRelease.Version, previousVersion)
 
 	previousRelease, err := r.cfg.Releases.Get(name, previousVersion)
diff --git a/pkg/chartutil/create.go b/pkg/chartutil/create.go
index e43aaf479..b073e1893 100644
--- a/pkg/chartutil/create.go
+++ b/pkg/chartutil/create.go
@@ -310,7 +310,7 @@ spec:
         {{- toYaml . | nindent 8 }}
       {{- end }}
       labels:
-        {{- include "<CHARTNAME>.labels" . | nindent 8 }}
+        {{- include "<CHARTNAME>.selectorLabels" . | nindent 8 }}
 	{{- with .Values.podLabels }}
         {{- toYaml . | nindent 8 }}
         {{- end }}
diff --git a/pkg/kube/client.go b/pkg/kube/client.go
index 0772678d1..f67008f0d 100644
--- a/pkg/kube/client.go
+++ b/pkg/kube/client.go
@@ -69,14 +69,6 @@ var ManagedFieldsManager string
 
 // Client represents a client capable of communicating with the Kubernetes API.
 type Client struct {
-	// Factory provides a minimal version of the kubectl Factory interface. If
-	// you need the full Factory you can type switch to the full interface.
-	// Since Kubernetes Go API does not provide backwards compatibility across
-	// minor versions, this API does not follow Helm backwards compatibility.
-	// Helm is exposing Kubernetes in this property and cannot guarantee this
-	// will not change. The minimal interface only has the functions that Helm
-	// needs. The smaller surface area of the interface means there is a lower
-	// chance of it changing.
 	Factory Factory
 	Log     func(string, ...interface{})
 	// Namespace allows to bypass the kubeconfig file for the choice of the namespace
diff --git a/pkg/kube/factory.go b/pkg/kube/factory.go
index f19d62dc3..6c1b0f4e3 100644
--- a/pkg/kube/factory.go
+++ b/pkg/kube/factory.go
@@ -26,12 +26,6 @@ import (
 
 // Factory provides abstractions that allow the Kubectl command to be extended across multiple types
 // of resources and different API sets.
-// This interface is a minimal copy of the kubectl Factory interface containing only the functions
-// needed by Helm. Since Kubernetes Go APIs, including interfaces, can change in any minor release
-// this interface is not covered by the Helm backwards compatibility guarantee. The reasons for the
-// minimal copy is that it does not include the full interface. Changes or additions to functions
-// Helm does not need are not impacted or exposed. This minimizes the impact of Kubernetes changes
-// being exposed.
 type Factory interface {
 	// ToRawKubeConfigLoader return kubeconfig loader as-is
 	ToRawKubeConfigLoader() clientcmd.ClientConfig
diff --git a/scripts/get b/scripts/get
index 594fd92c3..fce6abd99 100755
--- a/scripts/get
+++ b/scripts/get
@@ -207,10 +207,6 @@ while [[ $# -gt 0 ]]; do
        shift
        if [[ $# -ne 0 ]]; then
            export DESIRED_VERSION="${1}"
-           if [[ "$1" != "v"* ]]; then
-               echo "Expected version arg ('${DESIRED_VERSION}') to begin with 'v', fixing..."
-               export DESIRED_VERSION="v${1}"
-           fi
        else
            echo -e "Please provide the desired version. e.g. --version v2.4.0 or -v latest"
            exit 0
diff --git a/scripts/get-helm-3 b/scripts/get-helm-3
index b5e53bafc..4be52c3ed 100755
--- a/scripts/get-helm-3
+++ b/scripts/get-helm-3
@@ -305,10 +305,6 @@ while [[ $# -gt 0 ]]; do
        shift
        if [[ $# -ne 0 ]]; then
            export DESIRED_VERSION="${1}"
-           if [[ "$1" != "v"* ]]; then
-               echo "Expected version arg ('${DESIRED_VERSION}') to begin with 'v', fixing..."
-               export DESIRED_VERSION="v${1}"
-           fi
        else
            echo -e "Please provide the desired version. e.g. --version v3.0.0 or -v canary"
            exit 0


Test patch:
diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml
index 7696b4e21..85e1369b3 100644
--- a/.github/workflows/build-test.yml
+++ b/.github/workflows/build-test.yml
@@ -13,7 +13,7 @@ jobs:
     runs-on: ubuntu-latest
     steps:
       - name: Checkout source code
-        uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # pin@v3.6.0
+        uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # pin@v3.5.3
       - name: Setup Go
         uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # pin@4.1.0
         with:
diff --git a/cmd/helm/rollback_test.go b/cmd/helm/rollback_test.go
index 6d38e16eb..9ca921557 100644
--- a/cmd/helm/rollback_test.go
+++ b/cmd/helm/rollback_test.go
@@ -64,12 +64,6 @@ func TestRollbackCmd(t *testing.T) {
 		cmd:    "rollback funny-honey",
 		golden: "output/rollback-no-revision.txt",
 		rels:   rels,
-	}, {
-		name:      "rollback a release with non-existent version",
-		cmd:       "rollback funny-honey 3",
-		golden:    "output/rollback-non-existent-version.txt",
-		rels:      rels,
-		wantError: true,
 	}, {
 		name:      "rollback a release without release name",
 		cmd:       "rollback",
diff --git a/cmd/helm/testdata/output/rollback-non-existent-version.txt b/cmd/helm/testdata/output/rollback-non-existent-version.txt
deleted file mode 100644
index 9c2e10e17..000000000
--- a/cmd/helm/testdata/output/rollback-non-existent-version.txt
+++ /dev/null
@@ -1,1 +0,0 @@
-Error: release has no 3 version