Closed lwhile closed 2 years ago
The code below will cause panic in older versions of consul:
endpoints := []string{"http://127.0.0.1:8500"} libkv.AddStore(store.CONSUL, consul.New) store, err := libkv.NewStore(store.CONSUL, endpoints, nil)
panic: interface conversion: http.RoundTripper is nil, not *http.Transport [recovered] panic: interface conversion: http.RoundTripper is nil, not *http.Transport ... github.com/hashicorp/consul/api.NewClient(0xc4200942c0, 0x1, 0x1, 0x17)
The consul code that causes panic is: https://github.com/hashicorp/consul/blob/ae6bf56ee116fea921567d681067f920e7fc377b/api/api.go#L404
The code below will cause panic in older versions of consul:
The consul code that causes panic is: https://github.com/hashicorp/consul/blob/ae6bf56ee116fea921567d681067f920e7fc377b/api/api.go#L404