Potential regression on 0.1.6
Closed this issue · 1 comments
nnovaeshc commented
On version 0.1.5 running helm images get container-agent/container-agent --version 101.0.21
returns a version, but on version 0.1.6, the same command throws the error below. This does not happen with any helm repositories, i.e. helm images get reloader/reloader --version 1.1.0
works fine.
{"level":"warning","msg":"failed to get 'metadata' from the manifest","time":"2024-10-04T17:06:54Z"}
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x14500ed]
goroutine 1 [running]:
github.com/nikhilsbhat/helm-images/pkg/k8s.(*Kind).Get(0xc000081350, {0xc00024078a, 0x20}, 0xc0006b0680?)
github.com/nikhilsbhat/helm-images/pkg/k8s/k8s.go:110 +0x8d
github.com/nikhilsbhat/helm-images/pkg.(*Images).GetImages(0x323c620)
github.com/nikhilsbhat/helm-images/pkg/images.go:109 +0x276
github.com/nikhilsbhat/helm-images/cmd.getImagesCommand.func1(0xc00001e908?, {0xc0006a6f30?, 0x1?, 0x1f27939?})
github.com/nikhilsbhat/helm-images/cmd/register.go:72 +0x25
github.com/spf13/cobra.(*Command).execute(0xc00001e908, {0xc0006a6ed0, 0x3, 0x3})
github.com/spf13/cobra@v1.8.0/command.go:983 +0xaca
github.com/spf13/cobra.(*Command).ExecuteC(0xc00001ef08)
github.com/spf13/cobra@v1.8.0/command.go:1115 +0x3ff
github.com/nikhilsbhat/helm-images/cmd.execute(...)
github.com/nikhilsbhat/helm-images/cmd/cmd.go:30
github.com/nikhilsbhat/helm-images/cmd.Main()
github.com/nikhilsbhat/helm-images/cmd/cmd.go:21 +0x93
main.main()
github.com/nikhilsbhat/helm-images/main.go:8 +0xf
Error: plugin "images" exited with error
nikhilsbhat commented
The fix for this issue is included in this commit and will be released as part of the upcoming update.