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

Gocode panicked: `[deoplete] NoneType: None` #134

Closed
karlek opened this Issue Sep 19, 2018 · 3 comments

Comments

Projects
None yet
3 participants
@karlek
Copy link

karlek commented Sep 19, 2018

This minimal config panicks everytime a key is pressed when writing in a go file.

call plug#begin('~/.vim/plugged')
Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
Plug 'zchee/deoplete-go',    { 'do': 'make'}
call plug#end()
let g:deoplete#enable_at_startup = 1
let g:deoplete#sources#go#gocode_binary = '$GOPATH/bin/gocode'

There is very little information from the panic:

[deoplete] NoneType: None
gocode panicked.  Use :messages / see above for error details.
$ go version
go version go1.11 linux/amd64

[~/go/src/github.com/nsf/gocode] $ git rev-parse HEAD
7b1d4e18cdc58a74dc1bd4c2d45b3f1b2ca227c3
@Shougo

This comment has been minimized.

Copy link
Collaborator

Shougo commented Sep 20, 2018

You should use https://github.com/mdempsky/gocode instead.
nsf/gocode does not support go 1.10+.
Please read README in nsf/gocode.
https://github.com/nsf/gocode

@karlek

This comment has been minimized.

Copy link

karlek commented Sep 20, 2018

Thank you, that was the problem.

If someone else has this problem, don't forget to kill your old gocode daemon with gocode exit (or pkill gocode if necessary)

@cippaciong

This comment has been minimized.

Copy link

cippaciong commented Nov 2, 2018

If anyone using go modules stumbles into this issue and is already using mdempsky/gocode, please notice that mdempsky version does not support modules. As suggested in the README, try using stamblerre/gocode.
Remember to stop the daemon with gocode close, delete $GOPATH/bin/gocode and replace it with the newer version from stamblerre go get -u github.com/stamblerre/gocode

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment