go-langserver icon indicating copy to clipboard operation
go-langserver copied to clipboard

jsonrpc2 handle error

Open jenenliu opened this issue 7 years ago • 2 comments

Hi, I use emacs, and configure company-lsp and lsp-go for go mode, and I've found there is these errors keep annoying me.

jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\n'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\v'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\f'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\f'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\f'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\r'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\x0e'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\x0e'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\a' '\x00'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\a' '\x00'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\x00'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines
jsonrpc2 handler: notification "textDocument/didChange" handling error: received textDocument/didChange for invalid position {'\x06' '\x00'} on "file:///Users/jenenliu/go/src/tcpserver.go": file only has 6 lines

Mac High Sierra Emacs 26

thanks

jenenliu avatar Jul 09 '18 14:07 jenenliu

What text encoding is your file? This may be related to https://github.com/sourcegraph/go-langserver/issues/257 and https://github.com/sourcegraph/go-langserver/issues/277

keegancsmith avatar Jul 09 '18 19:07 keegancsmith

@keegancsmith my Emacs shows encoding is utf-8-unix, and I install go-langserver by go get -u github.com/sourcegraph/go-langserver, it should be the latest version, seems this is a different problem.

jenenliu avatar Jul 10 '18 01:07 jenenliu