Please complete these steps and check these boxes (by putting an x inside
the brackets) _before_ filing your issue:
vim --version.:YcmDebugInfo.:YcmToggleLogs stderr.Thank you for adhering to this process! It ensures your issue is resolved
quickly and that neither your nor our time is needlessly wasted.
[If filing a bug report, please include a list of steps that describe how to
reproduce the bug you are experiencing. Also include test code if relevant.]
I use the grpc to generate the proto file and import them in my project. But i cannot let the tags be complete by the ycm _ONLY IF I open that file_. Is there any way to make the YCM cache the tags automaticly or auto open the file which I import? How to make those tags which is in my import file (like grpc generate file) can be found automaticly?
here is some screen cut
1) keyin the . and callout the list

but there is nothing i need
2) after I open the file where the package was difined, they come out!

3) I paste some line about my vimrc file here

I wonder if I get something wrong with the config or something else.
Is there any way to make it easy and convenient to use YCM with go?
thx a lot
Please read and supply the details requested in CONTRIBUTING.md.
thx for reply me, now I HAVE read those docs
@arthurkiller Suggestions in your screenshots come from the identifier completer (indicated by the [ID] tag). From the documentation:
an identifier-based completer that collects all of the identifiers in the current file and other files you visit (and your tags files) and searches them when you type (identifiers are put into per-filetype groups).
What you really want is suggestions from the semantic completer. For the Go language, YCM use the gocode completion engine. To enable it, you need to install YCM with the --gocode-completer parameter:
./install.py --gocode-completer
Did you install it this way?
Sure, I do have install YCM with the --gocode-completer
But it doesn`t work.
Do I need to turn off the identifier of tags?
Do I need to turn off the identifier of tags?
No, we need to figure out why Gocode is not providing completions.
Did you install your proto file (.pb.go) with go install? This is required if you want completions from it because Gocode does not look at the sources but at the libraries. This is what I did with the grpc hello world example and it works.
Thx for reply.
I run go install and it works!
You mean the YCM will find the tags in the library (.a file) from my GOPATH/pkg right? So I should go install the third party package to make it be detected by YCM?
You mean the YCM will find the tags in the library (.a file) from my GOPATH/pkg right? So I should go install the third party package to make it be detected by YCM?
Yes and yes. See https://github.com/nsf/gocode/issues/256#issuecomment-62679489 from Gocode author.
Most helpful comment
Yes and yes. See https://github.com/nsf/gocode/issues/256#issuecomment-62679489 from Gocode author.