Faruk Hossain
Faruk Hossain

Reputation: 1203

"Cannot find declaration to go" protos declaration in IntelliJ IDEA

I am trying to use gRPC proto file to generate stub code for inter-service communication. Everything is okay and when I run mvn clean install, it installs everything and builds successfully.

But still now protos files are in red color and can’t go definition when I click to go to it’s definition. It says me Cannot find declaration to go. When build is successful then why it is not possible to find declaration in IntelliJ IDEA? I clean every cached on IDE and indexing is also successful. I also cleared m2 cache.

Is there anything to find this solution so that I can go to proto class definition?

Any help will be appreciated.

Thanks.

enter image description here

Upvotes: 1

Views: 522

Answers (1)

Faruk Hossain
Faruk Hossain

Reputation: 1203

Your IntelliJ IDEA  needs to generate Project setup. So you need to execute the main plugin goal, which is idea:idea. Use this command. It will helped me.

mvn -U idea:idea

Here -U = Forces a check for missing releases and updated snapshots on remote repositories

Upvotes: 1

Related Questions