Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grapi init does not work with non-example application names #288

Open
awildeep opened this issue Mar 30, 2021 · 1 comment
Open

Grapi init does not work with non-example application names #288

awildeep opened this issue Mar 30, 2021 · 1 comment

Comments

@awildeep
Copy link

awildeep commented Mar 30, 2021

When I run:

grapi init awesome-app

Grapi initializes properly:

➜ grapi init awesome-app
  ➜  Initialize project
     ╌  cmd/server/main.go
     ╌  cmd/server/run.go
     ╌  grapi.toml
     ╌  tools.go

  ▸  Install dependencies
go: downloading github.com/google/go-cmp v0.5.0
go: downloading github.com/bradleyjkemp/cupaloy/v2 v2.5.0
go: downloading github.com/golang/mock v1.2.0
go: downloading github.com/stretchr/testify v1.5.1
go: downloading github.com/onsi/ginkgo v1.6.0
go: downloading github.com/onsi/gomega v1.4.2
go: downloading github.com/pmezard/go-difflib v1.0.0
go: downloading gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127
go: downloading github.com/BurntSushi/toml v0.3.1
go: downloading golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543
go: downloading github.com/kr/pretty v0.1.0
go: downloading github.com/hpcloud/tail v1.0.0
go: downloading gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7
go: downloading gopkg.in/fsnotify.v1 v1.4.7
go: downloading github.com/kr/text v0.1.0
go: finding module for package google.golang.org/grpc/examples/helloworld/helloworld
go: downloading google.golang.org/grpc/examples v0.0.0-20210326170912-4a19753e9dfd
go: found google.golang.org/grpc/examples/helloworld/helloworld in google.golang.org/grpc/examples v0.0.0-20210326170912-4a19753e9dfd
go: downloading google.golang.org/genproto v0.0.0-20200806141610-86f49bd18e98

When I run:

grapi init anything-else-app

I get the following results:

➜ grapi init anything-else-app
  ➜  Initialize project
     ✔  cmd/server/main.go
     ✔  cmd/server/run.go
     ✔  grapi.toml
     ✔  tools.go

  ▸  Install dependencies
go: creating new go.mod: module anything-else-app
go: to add module requirements and sums:
	go mod tidy
go get: added github.com/izumin5210/grapi v0.5.0
go get: added github.com/srvc/appctx v0.1.0
go get: added google.golang.org/grpc v1.36.1
../../../pkg/mod/github.com/grpc-ecosystem/[email protected]/protoc-gen-grpc-gateway/descriptor/grpc_api_configuration.go:9:2: missing go.sum entry for module providing package github.com/ghodss/yaml (imported by github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway/descriptor); to add:
	go get github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway/[email protected]
../../../pkg/mod/github.com/grpc-ecosystem/[email protected]/protoc-gen-grpc-gateway/main.go:17:2: missing go.sum entry for module providing package github.com/golang/glog (imported by github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway); to add:
	go get github.com/grpc-ecosystem/grpc-gateway/[email protected]
failed to install dependencies: failed to build github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway: exit status 1

I have also tested at least a dozen other initialization names, all failed.

I expected grapi init anything-else-app to behave as grapi init awesome-app does, but create a different directory.

go version go1.16.2 darwin/amd64
dep version : v0.5.4
OSX: 11.2.3
Grapi installed via brew: grapi v0.5.0 (go1.13.1 darwin/amd64)

@rususlasan
Copy link

Have you tried to run suggested commands?

go get github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway/[email protected]
go get github.com/grpc-ecosystem/grpc-gateway/[email protected]

I had experienced same issue but after running go get ... init works fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants