maxbrunsfeld/counterfeiter

Go 1.14 leads to `internal error: nil Pkg importing ... from ...`

howardjohn opened this issue · 3 comments

After upgrading to golang 1.14 I am seeing failures:

Writing `ConfigStoreCache` to `../config/aggregate/fakes/config_store_cache.gen.go`...
loader.go:17: loading packages...
packages.go:800: internal error: nil Pkg importing "time" from "istio.io/istio/pilot/pkg/model"
pilot/pkg/model/config.go:206: running "counterfeiter": exit status 1

This is a known bug fixed in newer versions of go tools package: golang/go#33554

I have confirmed that upgrading this library fixes the issue for us. I will send a PR

update x/tools to latest not work for me...

I had to update the dependency here and rebuild the binary, not just in the package I was calling it on. See PR above, building that worked for me, but maybe there are other issues

@westwin
Update only x/tools not work for me. But after run go get -u all it worked