Is there an existing issue for this?
Kubernetes Version
No response
Shipwright Version
v0.16.0
Current Behavior
When listing BuildRun the CLI panics with the following error.
shp buildrun list -n test
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x8 pc=0x102603094]
goroutine 1 [running]:
github.com/shipwright-io/cli/pkg/shp/cmd/buildrun.(*ListCommand).Run(0x140009162b0, 0x140005582a0, 0x14000592e10)
/Users/sayan/code/github.com/shipwright/cli/pkg/shp/cmd/buildrun/list.go:110 +0x454
github.com/shipwright-io/cli/pkg/shp/cmd/runner.(*Runner).RunE(0x140005c2a00, 0xda2ed11489e4310f?, {0x140005c2fe0?, 0x0?, 0x0?})
/Users/sayan/code/github.com/shipwright/cli/pkg/shp/cmd/runner/runner.go:35 +0x90
github.com/spf13/cobra.(*Command).execute(0x1400091c908, {0x140005c2fc0, 0x2, 0x2})
/Users/sayan/code/github.com/shipwright/cli/vendor/github.com/spf13/cobra/command.go:1015 +0x844
github.com/spf13/cobra.(*Command).ExecuteC(0x1048b7180)
/Users/sayan/code/github.com/shipwright/cli/vendor/github.com/spf13/cobra/command.go:1148 +0x384
github.com/spf13/cobra.(*Command).Execute(0x14000592e10?)
/Users/sayan/code/github.com/shipwright/cli/vendor/github.com/spf13/cobra/command.go:1071 +0x1c
main.main()
/Users/sayan/code/github.com/shipwright/cli/cmd/shp/main.go:46 +0x110
Output from Kubectl
kubectl get buildrun -n test
NAME SUCCEEDED REASON STARTTIME COMPLETIONTIME
sample-buildah-2mdlt False Failed 70s 2s
sample-buildah-77pn6 False Failed 2d11h 2d11h
sample-buildah-b97qf False Failed 2d11h 2d11h
sample-buildah-cp8zc True Succeeded 2d10h 2d10h
sample-buildah-cr9kl False Failed 2d10h 2d10h
sample-buildah-vxzp5 False Failed 2d11h 2d11h
Expected Behavior
User should be able to list BuildRun resources.
Steps To Reproduce
- Install Shipwright in Kind or MiniKube cluster
- Install the Shipwright CLI
- Create
Build resource, with non-existing ClusterBuildStrategy
- Create
BuildRun resource in the cluster for the above Build, and this should fail because the Build resource validation had failed.
- Now list
BuildRun using shp buildrun list
Anything else?
No response
Is there an existing issue for this?
Kubernetes Version
No response
Shipwright Version
v0.16.0
Current Behavior
When listing
BuildRunthe CLI panics with the following error.Output from Kubectl
Expected Behavior
User should be able to list
BuildRunresources.Steps To Reproduce
Buildresource, with non-existingClusterBuildStrategyBuildRunresource in the cluster for the aboveBuild, and this should fail because theBuildresource validation had failed.BuildRunusingshp buildrun listAnything else?
No response