https://pulumi.com logo
#golang
Title
q

quaint-restaurant-18952

08/03/2021, 4:32 PM
Hi, trying to get going here with pulumi and golang. Im not to experienced in Go either, but wanted to try this combo.. anyways.. i fail pretty fast, but I belive it is from something that I'm not doing wrong.. running
pulumi new kubernetes-go
just takes me straigth to
Copy code
Installing dependencies...
go: <http://github.com/pulumi/pulumi/sdk/v3@v3.9.1|github.com/pulumi/pulumi/sdk/v3@v3.9.1> requires	<http://github.com/spf13/cobra@v1.0.0|github.com/spf13/cobra@v1.0.0> requires	<http://github.com/spf13/viper@v1.4.0|github.com/spf13/viper@v1.4.0> requires	<http://go.uber.org/zap@v1.10.0|go.uber.org/zap@v1.10.0>: verifying go.mod: <http://go.uber.org/zap@v1.10.0/go.mod|go.uber.org/zap@v1.10.0/go.mod>: malformed record data
When i checked https://pkg.go.dev/go.uber.org/zap@v1.10.0 it is reported as broken.. any suggestions to how to get around this?
b

billowy-army-68599

08/03/2021, 4:50 PM
Hmm I’ll give this a try myself, Go modules are notoriously…difficult
q

quaint-restaurant-18952

08/03/2021, 4:51 PM
cool, im running on mac, with
pulumi version  v3.9.1
straigth from homebrew.
b

billowy-army-68599

08/03/2021, 4:51 PM
Which Go version?
q

quaint-restaurant-18952

08/03/2021, 4:52 PM
go version go version go1.16.6 darwin/amd64
b

billowy-army-68599

08/03/2021, 5:42 PM
hey sorry for the delay here, I can't repro this! would you mind pasting your
go.mod
and
go.sum
into a github gist?
q

quaint-restaurant-18952

08/03/2021, 8:17 PM
go.mod
Copy code
module test-project-go

go 1.14

require (
	<http://github.com/pulumi/pulumi-kubernetes/sdk/v3|github.com/pulumi/pulumi-kubernetes/sdk/v3> v3.5.2
	<http://github.com/pulumi/pulumi/sdk/v3|github.com/pulumi/pulumi/sdk/v3> v3.9.1
)
I have no go.sum in my project as it fails to load zap.
here is the gist of the complete project and how far i get https://gist.github.com/spydx/403c8cc0341d2ed0b1fbf933d52f0f3d
b

billowy-army-68599

08/03/2021, 9:29 PM
can you clean your module cache?
Copy code
go clean --modcache
and then run
go mod tidy
q

quaint-restaurant-18952

08/04/2021, 6:04 AM
that seemed to work 😄
b

billowy-army-68599

08/04/2021, 2:09 PM
🎉
3 Views