Skip to content
This repository was archived by the owner on Jul 15, 2023. It is now read-only.

Go 1.11 - PANIC in autocomplete #1929

Closed
EmpireJones opened this issue Sep 14, 2018 · 9 comments
Closed

Go 1.11 - PANIC in autocomplete #1929

EmpireJones opened this issue Sep 14, 2018 · 9 comments

Comments

@EmpireJones
Copy link

Steps to Reproduce:

  1. Update to go 1.11
  2. Delete/reinstall all tools (delete bin/pkg folders)
  3. Restart vscode
  4. Get PANIC in autocomplete

I think I followed all relevant steps in #1888 but am still getting a panic. Are there any other steps required for upgrading to Go 1.11?

@strtob01
Copy link

strtob01 commented Sep 17, 2018

I tried a fresh install of Go 1.11 along with a fresh install of Visual Studio Code and also have the same problem on my Macbook.

@ramya-rao-a
Copy link
Contributor

Are you using the new modules feature? If yes, then its not yet supported. If not, then follow the below:

  • Close VS Code
  • Check for any running process for gocode. If you find it, kill it.
  • Open VS Code, Run Go: Install/Update Tools, select gocode and install it
  • Try for auto-completions

@strtob01
Copy link

No I'm not using the new modules feature. I tried the steps you mentioned but the autocompletion still panics.

@strtob01
Copy link

I just solved it. I had old gocode binaries in my PATH locations on my hard drive. I deleted all of them and the ran your instructions again and now it's working as expected.

@EmpireJones
Copy link
Author

I still haven't figured this one out. I have it working on one of two computers.

Killing gocode processes and reinstalling gocode didn't help. I also tried rebooting and reinstalling the vscode-go extension.

Is there any way to output details of the panic?

@EmpireJones
Copy link
Author

EmpireJones commented Sep 18, 2018

Figured out how to debug: gocode -s -debug from bin folder

Error is: panic: embedded struct field without name?
https://github.com/mdempsky/gocode/blob/master/internal/lookdot/lookdot.go#L77
not sure if that helps me though...

@bjm88
Copy link

bjm88 commented Sep 24, 2018

When do you plan to support the go 1.11 go.mod modules feature? I'm getting weird package errors like it can't find the local go packages. Example go.mod:
module company.com/product/identityservice

require (
cloud.google.com/go v0.28.0 // indirect
.....
)

replace company.com/product/go_common => ../go_common

@ramya-rao-a
Copy link
Contributor

Closing this issue because:

@EmpireJones
Copy link
Author

Thanks, I created mdempsky/gocode#66.
I'm not using go modules.

@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 11, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants