Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

panic for any command with new helm version #1427

Closed
Sceat opened this issue Aug 23, 2020 · 3 comments · Fixed by #1428
Closed

panic for any command with new helm version #1427

Sceat opened this issue Aug 23, 2020 · 3 comments · Fixed by #1428

Comments

@Sceat
Copy link

Sceat commented Aug 23, 2020

Seems the archlinux helm package got udpated and now when running helmfile it crash everytime

❯ helmfile lint                                                                                                                                                                                                      
panic: runtime error: index out of range [0] with length 0

goroutine 1 [running]:
github.com/roboll/helmfile/pkg/helmexec.getHelmVersion(0x15fab93, 0x4, 0xc000183150, 0x1b5f5e0, 0xc000028880, 0x447c01, 0xc0001d0101, 0xc00065dd40)
	/home/circleci/workspace/helmfile/pkg/helmexec/exec.go:68 +0x55c
github.com/roboll/helmfile/pkg/helmexec.New(...)
	/home/circleci/workspace/helmfile/pkg/helmexec/exec.go:106
github.com/roboll/helmfile/pkg/app.(*App).getHelm(0xc000476000, 0xc00024a000, 0x0, 0x0)
	/home/circleci/workspace/helmfile/pkg/app/app.go:555 +0x281
github.com/roboll/helmfile/pkg/app.(*App).visitStatesWithSelectorsAndRemoteSupport.func1(0xc00024a000, 0xc00024a000, 0x0, 0x0, 0xc0001bbb80)
	/home/circleci/workspace/helmfile/pkg/app/app.go:814 +0x41
github.com/roboll/helmfile/pkg/app.(*App).visitStates.func1(0x16056e1, 0xd, 0xc0001aa090, 0x28, 0x0, 0x0)
	/home/circleci/workspace/helmfile/pkg/app/app.go:654 +0x7ec
github.com/roboll/helmfile/pkg/app.(*App).visitStateFiles.func1(0x0, 0x15f9a15)
	/home/circleci/workspace/helmfile/pkg/app/app.go:488 +0x9d
github.com/roboll/helmfile/pkg/app.(*App).within(0xc000476000, 0x15f9a15, 0x1, 0xc00065e478, 0xc00065e438, 0x2)
	/home/circleci/workspace/helmfile/pkg/app/app.go:430 +0x602
github.com/roboll/helmfile/pkg/app.(*App).visitStateFiles(0xc000476000, 0x0, 0x0, 0x25e6d30, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
	/home/circleci/workspace/helmfile/pkg/app/app.go:482 +0x2f2
github.com/roboll/helmfile/pkg/app.(*App).visitStates(0xc000476000, 0x0, 0x0, 0x25e6d30, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
	/home/circleci/workspace/helmfile/pkg/app/app.go:566 +0x10b
github.com/roboll/helmfile/pkg/app.(*App).visitStatesWithSelectorsAndRemoteSupport(0xc000476000, 0x0, 0x0, 0xc00065e798, 0xc00065e800, 0x1, 0x1, 0x1, 0xc0000367a0)
	/home/circleci/workspace/helmfile/pkg/app/app.go:821 +0x4c1
github.com/roboll/helmfile/pkg/app.(*App).ForEachState(0xc000476000, 0xc00065e808, 0xc00065e800, 0x1, 0x1, 0x15d89e0, 0xc0006e2a60)
	/home/circleci/workspace/helmfile/pkg/app/app.go:702 +0xb2
github.com/roboll/helmfile/pkg/app.(*App).Lint(0xc000476000, 0x1b88300, 0xc0006e2a60, 0xc0006e2a60, 0xc000183150)
	/home/circleci/workspace/helmfile/pkg/app/app.go:234 +0xa9
main.main.func6(0xc000476000, 0xc0001de9a0, 0x0, 0xc0006e2a50, 0x0)
	/home/circleci/workspace/helmfile/main.go:288 +0x6d
main.action.func1(0xc0001de9a0, 0x0, 0xc0001de9a0)
	/home/circleci/workspace/helmfile/main.go:698 +0xd4
github.com/urfave/cli.HandleAction(0x1374140, 0xc0006e2570, 0xc0001de9a0, 0xc00009a600, 0x0)
	/home/circleci/workspace/helmfile/vendor/github.com/urfave/cli/app.go:490 +0xc8
github.com/urfave/cli.Command.Run(0x15fac53, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x162c4e8, 0x27, 0x0, ...)
	/home/circleci/workspace/helmfile/vendor/github.com/urfave/cli/command.go:210 +0x9e8
github.com/urfave/cli.(*App).Run(0xc000448d00, 0xc00018c000, 0x2, 0x2, 0x0, 0x0)
	/home/circleci/workspace/helmfile/vendor/github.com/urfave/cli/app.go:255 +0x741
main.main()
	/home/circleci/workspace/helmfile/main.go:500 +0x354d

I had to fallback on helm 3.2.4 to make it work

@AnatolyRugalev
Copy link
Contributor

AnatolyRugalev commented Aug 23, 2020

Looks like there is not patch version anymore in helm version output. I suppose helmfile should default to "0" if not patch version is present

$ helm version --short --client
v3.3

@AnatolyRugalev
Copy link
Contributor

I just checked official Releases page and figured that this particular official binary has proper version indication:

v3.3.0+g8a4aeec

So I'm not sure now how this should be fixed. Probably we should report helm issue to the helm archlinux contributor, but this may take some time

@AnatolyRugalev
Copy link
Contributor

Hey @Sceat!

I just updated helmfile package in AUR, so this one should be fixed.

Have a nice day!

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 a pull request may close this issue.

2 participants