You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried to find an explanation for this, but i can't seem to succeed...
Whenever i try to run gotype -t -e main.go, i get the following error:
main.go:4:2: could not import myproject/cmd (type-checking package "myproject/cmd" failed (/<path>/backend/cmd/root.go:6:2: could not import github.com/spf13/viper (type-checking package "github.com/spf13/viper" failed (/Users/corentin/go/pkg/mod/github.com/spf13/[email protected]/flags.go:3:8: could not import github.com/spf13/pflag (go/build: importGo github.com/spf13/pflag: exit status 1
error writing go.mod: open /Users/corentin/go/pkg/mod/github.com/spf13/[email protected]/go.mod298498081.tmp: permission denied
)))))
zsh: exit 2 gotype -t -e main.go
It seems as if a temporary go.mod was required or something. If i completely comment out viper from my project, it will give the expected result.
Also - and that's when it gets really weird - if i keep viper in my project I will get the error when running gotype in a terminal but not when it's running in sublime-linter-gotype. In this case, i get the correct linting.
The text was updated successfully, but these errors were encountered:
I tried to find an explanation for this, but i can't seem to succeed...
Whenever i try to run
gotype -t -e main.go
, i get the following error:It seems as if a temporary go.mod was required or something. If i completely comment out viper from my project, it will give the expected result.
Also - and that's when it gets really weird - if i keep viper in my project I will get the error when running gotype in a terminal but not when it's running in sublime-linter-gotype. In this case, i get the correct linting.
The text was updated successfully, but these errors were encountered: