Skip to content
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

Workspace loading: 0 / 0 #2336

Open
CodesOtakuYT opened this issue Sep 19, 2023 · 2 comments
Open

Workspace loading: 0 / 0 #2336

CodesOtakuYT opened this issue Sep 19, 2023 · 2 comments
Labels
Non VS Code The server is communicating with a client that is not VS Code

Comments

@CodesOtakuYT
Copy link

CodesOtakuYT commented Sep 19, 2023

How are you using the lua-language-server?

Other

Which OS are you using?

Linux

What is the issue affecting?

Hover

Expected Behaviour

I expected the result of the hover

Actual Behaviour

{"id":3,"jsonrpc":"2.0","result":{"contents":{"kind":"markdown","value":"Workspace loading: 0 / 0"}}}

Reproduction steps

Am creating an lsp client

Additional Notes

No response

Log File

Log file
[23:28:07.103][info] [#0:/usr/lib/lua-language-server/main.lua:66]: Lua Lsp startup, root: 	/usr/lib/lua-language-server
[23:28:07.103][info] [#0:/usr/lib/lua-language-server/main.lua:67]: ROOT:	/usr/lib/lua-language-server
[23:28:07.103][info] [#0:/usr/lib/lua-language-server/main.lua:68]: LOGPATH:	../../../log
[23:28:07.103][info] [#0:/usr/lib/lua-language-server/main.lua:69]: METAPATH:	/tmp/lua-language-server-1000/instance.FGRv/meta
[23:28:07.103][info] [#0:/usr/lib/lua-language-server/main.lua:70]: VERSION:	<Unknown>
[23:28:07.135][debug][#0:script/pub/pub.lua:50]: Create brave:	1
[23:28:07.135][debug][#0:script/pub/pub.lua:50]: Create brave:	2
[23:28:07.136][debug][#0:script/pub/pub.lua:50]: Create brave:	3
[23:28:07.136][debug][#0:script/pub/pub.lua:50]: Create brave:	4
[23:28:07.136][info] [#0:script/service/service.lua:144]: 
========= Medical Examination Report =========
    --------------- Memory ---------------
        Total: 2.115 MB
        # 00 : 2.115 MB
        # 01 : 0.000 MB
        # 02 : 0.000 MB
        # 03 : 0.000 MB
        # 04 : 0.000 MB
    --------------- Coroutine ---------------
        Total:     0
        Running:   0
        Suspended: 0
        Normal:    0
        Dead:      0
    --------------- Cache ---------------
        Total: 1
        Dead:  0
    ---------------  RPC  ---------------
        Holdon:   0
        Waiting:  0
==============================================
[23:28:07.339][info] [#0:script/proto/proto.lua:25]: rpc recieve:	{"id":2,"jsonrpc":"2.0","method":"initialize","params":{"capabilities":[],"processId":24039}}
[23:28:07.340][info] [#0:script/client.lua:657]: Client init	{
  capabilities = {},
  processId = 24039
}
[23:28:07.340][info] [#0:script/language.lua:137]: VSC language: nil
[23:28:07.340][info] [#0:script/language.lua:138]: LS  language: en-us
[23:28:07.342][debug][#0:script/provider/provider.lua:129]: Server init	{
  capabilities = {
    codeActionProvider = {
      codeActionKinds = { "", "quickfix", "refactor.rewrite", "refactor.extract" },
      resolveProvider = false
    },
    codeLensProvider = {
      resolveProvider = true
    },
    colorProvider = true,
    completionProvider = {
      resolveProvider = true,
      triggerCharacters = { "\t", "\n", ".", ":", "(", "'", '"', "[", ",", "#", "*", "@", "|", "=", "-", "{", " ", "+", "?" }
    },
    definitionProvider = true,
    documentFormattingProvider = true,
    documentHighlightProvider = true,
    documentOnTypeFormattingProvider = {
      firstTriggerCharacter = "\n"
    },
    documentRangeFormattingProvider = true,
    documentSymbolProvider = true,
    executeCommandProvider = {
      commands = { "lua.removeSpace", "lua.solve", "lua.jsonToLua", "lua.setConfig", "lua.getConfig", "lua.autoRequire" }
    },
    foldingRangeProvider = true,
    hoverProvider = true,
    inlayHintProvider = {
      resolveProvider = true
    },
    offsetEncoding = "utf-16",
    referencesProvider = true,
    renameProvider = {
      prepareProvider = true
    },
    semanticTokensProvider = {
      full = true,
      legend = {
        tokenModifiers = { "declaration", "definition", "readonly", "static", "deprecated", "abstract", "async", "modification", "documentation", "defaultLibrary", "global" },
        tokenTypes = { "namespace", "type", "class", "enum", "interface", "struct", "typeParameter", "parameter", "variable", "property", "enumMember", "event", "function", "method", "macro", "keyword", "modifier", "comment", "string", "number", "regexp", "operator", "decorator" }
      },
      range = true
    },
    signatureHelpProvider = {
      triggerCharacters = { "(", "," }
    },
    textDocumentSync = {
      change = 2,
      openClose = true,
      save = {
        includeText = false
      }
    },
    typeDefinitionProvider = true,
    workspace = {
      fileOperations = {
        didRename = {
          filters = {}
        }
      },
      workspaceFolders = {
        changeNotifications = true,
        supported = true
      }
    },
    workspaceSymbolProvider = true
  },
  serverInfo = {
    name = "sumneko.lua"
  }
}
[23:28:07.342][info] [#0:script/proto/proto.lua:18]: rpc send:	Content-Length: 1759

{"id":2,"jsonrpc":"2.0","result":{"capabilities":{"codeActionProvider":{"codeActionKinds":["","quickfix","refactor.rewrite","refactor.extract"],"resolveProvider":false},"codeLensProvider":{"resolveProvider":true},"colorProvider":true,"completionProvider":{"resolveProvider":true,"triggerCharacters":["\t","\n",".",":","(","'","\"","[",",","#","*","@","|","=","-","{"," ","+","?"]},"definitionProvider":true,"documentFormattingProvider":true,"documentHighlightProvider":true,"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"\n"},"documentRangeFormattingProvider":true,"documentSymbolProvider":true,"executeCommandProvider":{"commands":["lua.removeSpace","lua.solve","lua.jsonToLua","lua.setConfig","lua.getConfig","lua.autoRequire"]},"foldingRangeProvider":true,"hoverProvider":true,"inlayHintProvider":{"resolveProvider":true},"offsetEncoding":"utf-16","referencesProvider":true,"renameProvider":{"prepareProvider":true},"semanticTokensProvider":{"full":true,"legend":{"tokenModifiers":["declaration","definition","readonly","static","deprecated","abstract","async","modification","documentation","defaultLibrary","global"],"tokenTypes":["namespace","type","class","enum","interface","struct","typeParameter","parameter","variable","property","enumMember","event","function","method","macro","keyword","modifier","comment","string","number","regexp","operator","decorator"]},"range":true},"signatureHelpProvider":{"triggerCharacters":["(",","]},"textDocumentSync":{"change":2,"openClose":true,"save":{"includeText":false}},"typeDefinitionProvider":true,"workspace":{"fileOperations":{"didRename":{"filters":[]}},"workspaceFolders":{"changeNotifications":true,"supported":true}},"workspaceSymbolProvider":true},"serverInfo":{"name":"sumneko.lua"}}}
[23:28:07.345][info] [#0:script/proto/proto.lua:18]: rpc send:	Content-Length: 120

{"jsonrpc":"2.0","method":"$/status/report","params":{"text":"😺Lua","tooltip":"Cached files: 0/0\nMemory usage: 2M"}}
[23:28:07.445][info] [#0:script/proto/proto.lua:25]: rpc recieve:	{"id":3,"jsonrpc":"2.0","method":"textDocument/hover","params":{"position":{"character":1,"line":1},"textDocument":{"uri":"file:///home/codotaku/Documents/Projects/project1/test.lua"}}}
[23:28:07.445][info] [#0:script/proto/proto.lua:18]: rpc send:	Content-Length: 101

{"id":3,"jsonrpc":"2.0","result":{"contents":{"kind":"markdown","value":"Workspace loading: 0 / 0"}}}
[23:28:14.042][warn] [#0:script/pub/report.lua:25]: Load proto error:	Disconnected!
@carsakiller carsakiller added the Non VS Code The server is communicating with a client that is not VS Code label Sep 24, 2023
@nospam2998
Copy link

nospam2998 commented Oct 6, 2023

@CodesOtakuYT wrote:

Am creating an lsp client

Did you implement workspace/configuration in your client? This language server is buggy (or rather designed to only work with VSCode) towards all clients not implementing that method call. This bug is analyzed and summarized in #2318 (of which this ticket might perhaps be considered a duplicate?).

In case the cause is as above, could you please check whether the fix on the fix/honour_configuration_capability branch makes this language server work for you?

@nospam2998
Copy link

I believe this issue is a duplicate of #2318 and thus fixed by the merge of #2843. Could you please confirm, @CodesOtakuYT?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Non VS Code The server is communicating with a client that is not VS Code
Projects
None yet
Development

No branches or pull requests

3 participants