mattn / efm-langserver

General purpose Language Server
MIT License
1.35k stars 61 forks source link

cannot unmarshal array into Go struct #158

Closed dhruvinsh closed 3 years ago

dhruvinsh commented 3 years ago

On my Linux server I have been getting this error:

2021/08/09 13:25:25 jsonrpc2 handler: notification "workspace/didChangeConfiguration" handling error: json: cannot unmarshal array into Go struct field Config.settings.languages of type langserver.Language\n

Go version:

go version go1.16.7 linux/amd64

efm server version:

efm-langserver 0.0.36 (rev: HEAD/go1.16.7)
dhruvinsh commented 3 years ago

Closing it for #137

dhruvinsh commented 3 years ago

it is solved. with the config logic, final output was something like below,

settings = {
  languages = {
    lua = { stylua, selene }
    python = { {}, {} }
  }
}

fixing that python formatter fix the issue.