plutov/packagemain

13-go-kit-2 users service throwing package path errors

najamsk opened this issue · 2 comments

Pulling myhair now to make these eorrors go away.
packagemain/13-go-kit-2
➜ docker-compose up users

Starting users ... done
Attaching to users
users | 2020/01/07 08:20:55 build started
users | Building github.com/plutov/packagemain/13-go-kit-2/users/cmd...
users | ../../13-go-kit-2/users/cmd/service/service.go:12:2: cannot find package "github.com/go-kit/kit/endpoint" in any of:
users | /usr/local/go/src/github.com/go-kit/kit/endpoint (from $GOROOT)
users | /go/src/github.com/go-kit/kit/endpoint (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:13:2: cannot find package "github.com/go-kit/kit/log" in any of:
users | /usr/local/go/src/github.com/go-kit/kit/log (from $GOROOT)
users | /go/src/github.com/go-kit/kit/log (from $GOPATH)
users | ../../13-go-kit-2/users/pkg/endpoint/middleware.go:8:2: cannot find package "github.com/go-kit/kit/metrics" in any of:
users | /usr/local/go/src/github.com/go-kit/kit/metrics (from $GOROOT)
users | /go/src/github.com/go-kit/kit/metrics (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:14:2: cannot find package "github.com/go-kit/kit/metrics/prometheus" in any of:
users | /usr/local/go/src/github.com/go-kit/kit/metrics/prometheus (from $GOROOT)
users | /go/src/github.com/go-kit/kit/metrics/prometheus (from $GOPATH)
users | ../../13-go-kit-2/users/pkg/service/service.go:7:2: cannot find package "github.com/go-kit/kit/sd/etcd" in any of:
users | /usr/local/go/src/github.com/go-kit/kit/sd/etcd (from $GOROOT)
users | /go/src/github.com/go-kit/kit/sd/etcd (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service_gen.go:8:2: cannot find package "github.com/go-kit/kit/tracing/opentracing" in any of:
users | /usr/local/go/src/github.com/go-kit/kit/tracing/opentracing (from $GOROOT)
users | /go/src/github.com/go-kit/kit/tracing/opentracing (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service_gen.go:9:2: cannot find package "github.com/go-kit/kit/transport/http" in any of:
users | /usr/local/go/src/github.com/go-kit/kit/transport/http (from $GOROOT)
users | /go/src/github.com/go-kit/kit/transport/http (from $GOPATH)
users | ../../13-go-kit-2/notificator/pkg/grpc/pb/notificator.pb.go:6:8: cannot find package "github.com/golang/protobuf/proto" in any of:
users | /usr/local/go/src/github.com/golang/protobuf/proto (from $GOROOT)
users | /go/src/github.com/golang/protobuf/proto (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:15:2: cannot find package "github.com/lightstep/lightstep-tracer-go" in any of:
users | /usr/local/go/src/github.com/lightstep/lightstep-tracer-go (from $GOROOT)
users | /go/src/github.com/lightstep/lightstep-tracer-go (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:16:2: cannot find package "github.com/oklog/oklog/pkg/group" in any of:
users | /usr/local/go/src/github.com/oklog/oklog/pkg/group (from $GOROOT)
users | /go/src/github.com/oklog/oklog/pkg/group (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:17:2: cannot find package "github.com/opentracing/opentracing-go" in any of:
users | /usr/local/go/src/github.com/opentracing/opentracing-go (from $GOROOT)
users | /go/src/github.com/opentracing/opentracing-go (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:18:2: cannot find package "github.com/openzipkin-contrib/zipkin-go-opentracing" in any of:
users | /usr/local/go/src/github.com/openzipkin-contrib/zipkin-go-opentracing (from $GOROOT)
users | /go/src/github.com/openzipkin-contrib/zipkin-go-opentracing (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:22:2: cannot find package "github.com/prometheus/client_golang/prometheus" in any of:
users | /usr/local/go/src/github.com/prometheus/client_golang/prometheus (from $GOROOT)
users | /go/src/github.com/prometheus/client_golang/prometheus (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:23:2: cannot find package "github.com/prometheus/client_golang/prometheus/promhttp" in any of:
users | /usr/local/go/src/github.com/prometheus/client_golang/prometheus/promhttp (from $GOROOT)
users | /go/src/github.com/prometheus/client_golang/prometheus/promhttp (from $GOPATH)
users | ../../13-go-kit-2/notificator/pkg/grpc/pb/notificator.pb.go:11:2: cannot find package "golang.org/x/net/context" in any of:
users | /usr/local/go/src/golang.org/x/net/context (from $GOROOT)
users | /go/src/golang.org/x/net/context (from $GOPATH)
users | ../../13-go-kit-2/notificator/pkg/grpc/pb/notificator.pb.go:12:2: cannot find package "google.golang.org/grpc" in any of:
users | /usr/local/go/src/google.golang.org/grpc (from $GOROOT)
users | /go/src/google.golang.org/grpc (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:24:2: cannot find package "sourcegraph.com/sourcegraph/appdash" in any of:
users | /usr/local/go/src/sourcegraph.com/sourcegraph/appdash (from $GOROOT)
users | /go/src/sourcegraph.com/sourcegraph/appdash (from $GOPATH)
users | ../../13-go-kit-2/users/cmd/service/service.go:25:2: cannot find package "sourcegraph.com/sourcegraph/appdash/opentracing" in any of:
users | /usr/local/go/src/sourcegraph.com/sourcegraph/appdash/opentracing (from $GOROOT)
users | /go/src/sourcegraph.com/sourcegraph/appdash/opentracing (from $GOPATH)
users | An error occurred while building: exit status 1
^CGracefully stopping... (press Ctrl+C again to force)
Stopping users ... done

packagemain/13-go-kit-2 on
➜ docker-compose up notificator
Creating notificator ... done
Attaching to notificator
notificator | 2020/01/07 08:42:24 build started
notificator | Building github.com/plutov/packagemain/13-go-kit-2/notificator/cmd...
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:13:2: cannot find package "github.com/go-kit/kit/endpoint" in any of:
notificator | /usr/local/go/src/github.com/go-kit/kit/endpoint (from $GOROOT)
notificator | /go/src/github.com/go-kit/kit/endpoint (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:14:2: cannot find package "github.com/go-kit/kit/log" in any of:
notificator | /usr/local/go/src/github.com/go-kit/kit/log (from $GOROOT)
notificator | /go/src/github.com/go-kit/kit/log (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/pkg/endpoint/middleware.go:8:2: cannot find package "github.com/go-kit/kit/metrics" in any of:
notificator | /usr/local/go/src/github.com/go-kit/kit/metrics (from $GOROOT)
notificator | /go/src/github.com/go-kit/kit/metrics (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:15:2: cannot find package "github.com/go-kit/kit/metrics/prometheus" in any of:
notificator | /usr/local/go/src/github.com/go-kit/kit/metrics/prometheus (from $GOROOT)
notificator | /go/src/github.com/go-kit/kit/metrics/prometheus (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:16:2: cannot find package "github.com/go-kit/kit/sd/etcd" in any of:
notificator | /usr/local/go/src/github.com/go-kit/kit/sd/etcd (from $GOROOT)
notificator | /go/src/github.com/go-kit/kit/sd/etcd (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service_gen.go:8:2: cannot find package "github.com/go-kit/kit/tracing/opentracing" in any of:
notificator | /usr/local/go/src/github.com/go-kit/kit/tracing/opentracing (from $GOROOT)
notificator | /go/src/github.com/go-kit/kit/tracing/opentracing (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service_gen.go:9:2: cannot find package "github.com/go-kit/kit/transport/grpc" in any of:
notificator | /usr/local/go/src/github.com/go-kit/kit/transport/grpc (from $GOROOT)
notificator | /go/src/github.com/go-kit/kit/transport/grpc (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/pkg/grpc/pb/notificator.pb.go:6:8: cannot find package "github.com/golang/protobuf/proto" in any of:
notificator | /usr/local/go/src/github.com/golang/protobuf/proto (from $GOROOT)
notificator | /go/src/github.com/golang/protobuf/proto (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:17:2: cannot find package "github.com/lightstep/lightstep-tracer-go" in any of:
notificator | /usr/local/go/src/github.com/lightstep/lightstep-tracer-go (from $GOROOT)
notificator | /go/src/github.com/lightstep/lightstep-tracer-go (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:18:2: cannot find package "github.com/oklog/oklog/pkg/group" in any of:
notificator | /usr/local/go/src/github.com/oklog/oklog/pkg/group (from $GOROOT)
notificator | /go/src/github.com/oklog/oklog/pkg/group (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:19:2: cannot find package "github.com/opentracing/opentracing-go" in any of:
notificator | /usr/local/go/src/github.com/opentracing/opentracing-go (from $GOROOT)
notificator | /go/src/github.com/opentracing/opentracing-go (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:20:2: cannot find package "github.com/openzipkin-contrib/zipkin-go-opentracing" in any of:
notificator | /usr/local/go/src/github.com/openzipkin-contrib/zipkin-go-opentracing (from $GOROOT)
notificator | /go/src/github.com/openzipkin-contrib/zipkin-go-opentracing (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:25:2: cannot find package "github.com/prometheus/client_golang/prometheus" in any of:
notificator | /usr/local/go/src/github.com/prometheus/client_golang/prometheus (from $GOROOT)
notificator | /go/src/github.com/prometheus/client_golang/prometheus (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:26:2: cannot find package "github.com/prometheus/client_golang/prometheus/promhttp" in any of:
notificator | /usr/local/go/src/github.com/prometheus/client_golang/prometheus/promhttp (from $GOROOT)
notificator | /go/src/github.com/prometheus/client_golang/prometheus/promhttp (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/pkg/service/service.go:6:2: cannot find package "github.com/satori/go.uuid" in any of:
notificator | /usr/local/go/src/github.com/satori/go.uuid (from $GOROOT)
notificator | /go/src/github.com/satori/go.uuid (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/pkg/grpc/pb/notificator.pb.go:11:2: cannot find package "golang.org/x/net/context" in any of:
notificator | /usr/local/go/src/golang.org/x/net/context (from $GOROOT)
notificator | /go/src/golang.org/x/net/context (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/pkg/grpc/pb/notificator.pb.go:12:2: cannot find package "google.golang.org/grpc" in any of:
notificator | /usr/local/go/src/google.golang.org/grpc (from $GOROOT)
notificator | /go/src/google.golang.org/grpc (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:28:2: cannot find package "sourcegraph.com/sourcegraph/appdash" in any of:
notificator | /usr/local/go/src/sourcegraph.com/sourcegraph/appdash (from $GOROOT)
notificator | /go/src/sourcegraph.com/sourcegraph/appdash (from $GOPATH)
notificator | ../../13-go-kit-2/notificator/cmd/service/service.go:29:2: cannot find package "sourcegraph.com/sourcegraph/appdash/opentracing" in any of:
notificator | /usr/local/go/src/sourcegraph.com/sourcegraph/appdash/opentracing (from $GOROOT)
notificator | /go/src/sourcegraph.com/sourcegraph/appdash/opentracing (from $GOPATH)
notificator | An error occurred while building: exit status 1

@najamsk this code was old and some dependencies were updated. I added go modules so now it works, please try again.