vmware-tanzu / tanzu-framework

Tanzu Framework provides a set of building blocks to build atop of the Tanzu platform and leverages Carvel packaging and plugins to provide users with a much stronger, more integrated experience than the loose coupling and stand-alone commands of the previous generation of tools.
Apache License 2.0
197 stars 193 forks source link

Strange ERROR returned when .config/tanzu folder is not present #249

Open joshrosso opened 3 years ago

joshrosso commented 3 years ago

Bug description

If a user does not have a pre-existing ~/.config/tanzu directory and creates a mangement-cluster, they are given the following error.

ERROR 2021/07/20 19:45:50 svType != tvType; key=release, st=map[string]interface {}, tt=<nil>, sv=map[version:], tv=<nil>

Affected product area (please put an X in all that apply)

Steps to reproduce the bug

  1. Remove the tanzu config directory.

    rm -rv ~/.config/tanzu
  2. Create a management cluster.

     CLUSTER_PLAN=dev tanzu management-cluster create -i docker
  3. Observe the error message.

    tce@tce:~$ CLUSTER_PLAN=dev tanzu management-cluster create -i docker
    ERROR 2021/07/20 19:45:50 svType != tvType; key=release, st=map[string]interface {}, tt=<nil>, sv=map[version:], tv=<nil>

Version (include the SHA if the version is not obvious)

latest commit: 92bf7ffbdcbd1c7955e1feafa0a2f9490826ac20

ncdc commented 3 years ago

FYI this error comes from Viper (https://github.com/spf13/viper/blob/a7cfd8b8e030fea088a8867ea1b5a0e59ac2e2cc/viper.go#L1816)