From 1bc4381693485b2e8246998c92e65f126776b22f Mon Sep 17 00:00:00 2001 From: Radek Simko Date: Wed, 27 May 2020 14:29:00 +0100 Subject: [PATCH] langserver: Make requests sequential --- langserver/langserver.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/langserver/langserver.go b/langserver/langserver.go index 12aa7bf32..3dfadb46b 100644 --- a/langserver/langserver.go +++ b/langserver/langserver.go @@ -28,6 +28,10 @@ type langServer struct { func NewLangServer(srvCtx context.Context, sf session.SessionFactory) *langServer { opts := &jrpc2.ServerOptions{ AllowPush: true, + + // Disable concurrency to avoid race conditions + // between requests concerning the same document + Concurrency: 1, } return &langServer{