Coc.nvim: ccls server wont start, exits with code null

Created on 8 Apr 2019  路  11Comments  路  Source: neoclide/coc.nvim

Result from CocInfo

## versions

vim version: NVIM v0.4.0-490-g157034bd6
node version: v8.15.1
coc.nvim version: 0.0.64-615c4b2d9d
term: rxvt-unicode-256color
platform: linux

## Error messages

## Output channel: snippets
[Error 6:14:55 PM] Convert regex error for: li(st)? (?<num>\d+)$
[Error 6:14:55 PM] Convert regex error for: ol(st)? (?<num>\d+)$

## Output channel: languageserver.ccls
18:14:55 ccls           initialize.cc:271 I initialize in directory /home/yhamdoud with uri file:///home/yhamdoud
18:14:55 ccls           initialize.cc:294 I initializationOptions: {"compilationDatabaseCommand":"","compilationDatabaseDirectory":"","cache":{"directory":".ccls-cache","format":"binary","hierarchicalPath":false,"retainInMemory":2},"capabilities":{"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"}","moreTriggerCharacter":[]},"foldingRangeProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true}}},"clang":{"excludeArgs":[],"extraArgs":[],"pathMappings":[],"resourceDir":""},"client":{"hierarchicalDocumentSymbolSupport":true,"linkSupport":true,"snippetSupport":true},"codeLens":{"localVariables":true},"completion":{"caseSensitivity":2,"detailedLabel":true,"dropOldRequests":true,"duplicateOptional":true,"filterAndSort":true,"include":{"blacklist":[],"maxPathSize":30,"suffixWhitelist":[".h",".hpp",".hh",".inc"],"whitelist":[]},"maxNum":100},"diagnostics":{"blacklist":[],"onChange":1000,"onOpen":0,"onSave":0,"spellChecking":true,"whitelist":[]},"highlight":{"largeFileSize":2097152,"lsRanges":false,"blacklist":[],"whitelist":[]},"index":{"blacklist":[],"comments":2,"initialNoLinkage":false,"initialBlacklist":[],"initialWhitelist":[],"maxInitializerLines":5,"multiVersion":0,"multiVersionBlacklist":[],"multiVersionWhitelist":[],"name":{"suppressUnwrittenScope":false},"onChange":false,"parametersInDeclarations":true,"threads":0,"trackDependency":2,"whitelist":[]},"request":{"timeout":5000},"session":{"maxNum":10},"workspaceSymbol":{"caseSensitivity":1,"maxNum":1000,"sort":true},"xref":{"maxNum":2000}}
18:14:55 ccls           initialize.cc:323 I use -resource-dir=/usr/lib/clang/8.0.0
18:14:55 ccls           initialize.cc:356 I workspace folder: /home/yhamdoud/
18:14:55 ccls           initialize.cc:381 I start 4 indexers
18:14:55 ccls           initialize.cc:389 I dispatch initial index requests
18:14:55 ccls             pipeline.cc:478 I loaded project. Refresh semantic highlight for all working file.
18:14:55 indexer1         pipeline.cc:344 I delete /home/yhamdoud/test.c
18:14:55 preamble     sema_manager.cc:733 I create session for /home/yhamdoud/test.c
 #0 0x00007ff453edc0bb llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/usr/lib/libLLVM-8.so+0x9f60bb)
 #1 0x00007ff453ed9f64 llvm::sys::RunSignalHandlers() (/usr/lib/libLLVM-8.so+0x9f3f64)
 #2 0x00007ff453eda0ee (/usr/lib/libLLVM-8.so+0x9f40ee)
 #3 0x00007ff45332c3c0 __restore_rt (/usr/lib/libpthread.so.0+0x123c0)
 #4 0x000055e74747e237 (ccls+0x27237)
 #5 0x00007ff453e9c77b (/usr/lib/libLLVM-8.so+0x9b677b)
 #6 0x000055e7474ed822 (ccls+0x96822)
 #7 0x00007ff457dbd3b1 (/usr/lib/libclangDriver.so.8+0x1233b1)
 #8 0x00007ff457dbe360 (/usr/lib/libclangDriver.so.8+0x124360)
 #9 0x00007ff457dd7015 (/usr/lib/libclangDriver.so.8+0x13d015)
#10 0x00007ff457d08b7b clang::driver::Driver::getToolChain(llvm::opt::ArgList const&, llvm::Triple const&) const (/usr/lib/libclangDriver.so.8+0x6eb7b)
#11 0x00007ff457d146a4 clang::driver::Driver::BuildCompilation(llvm::ArrayRef<char const*>) (/usr/lib/libclangDriver.so.8+0x7a6a4)
#12 0x00007ff458d627a3 clang::createInvocationFromCommandLine(llvm::ArrayRef<char const*>, llvm::IntrusiveRefCntPtr<clang::DiagnosticsEngine>, llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem>) (/usr/lib/libclangFrontend.so.8+0xc47a3)
#13 0x000055e74747c157 (ccls+0x25157)
#14 0x000055e7474ec3b2 (ccls+0x953b2)
#15 0x00007ff453321a9d start_thread (/usr/lib/libpthread.so.0+0x7a9d)
#16 0x00007ff453251b23 __GI___clone (/usr/lib/libc.so.6+0xfbb23)
[Info  - 6:14:55 PM] Connection to server got closed. Server will restart.
[Error  - 6:14:56 PM] ccls exited with code: null
18:14:56 ccls           initialize.cc:271 I initialize in directory /home/yhamdoud with uri file:///home/yhamdoud
18:14:56 ccls           initialize.cc:294 I initializationOptions: {"compilationDatabaseCommand":"","compilationDatabaseDirectory":"","cache":{"directory":".ccls-cache","format":"binary","hierarchicalPath":false,"retainInMemory":2},"capabilities":{"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"}","moreTriggerCharacter":[]},"foldingRangeProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true}}},"clang":{"excludeArgs":[],"extraArgs":[],"pathMappings":[],"resourceDir":""},"client":{"hierarchicalDocumentSymbolSupport":true,"linkSupport":true,"snippetSupport":true},"codeLens":{"localVariables":true},"completion":{"caseSensitivity":2,"detailedLabel":true,"dropOldRequests":true,"duplicateOptional":true,"filterAndSort":true,"include":{"blacklist":[],"maxPathSize":30,"suffixWhitelist":[".h",".hpp",".hh",".inc"],"whitelist":[]},"maxNum":100},"diagnostics":{"blacklist":[],"onChange":1000,"onOpen":0,"onSave":0,"spellChecking":true,"whitelist":[]},"highlight":{"largeFileSize":2097152,"lsRanges":false,"blacklist":[],"whitelist":[]},"index":{"blacklist":[],"comments":2,"initialNoLinkage":false,"initialBlacklist":[],"initialWhitelist":[],"maxInitializerLines":5,"multiVersion":0,"multiVersionBlacklist":[],"multiVersionWhitelist":[],"name":{"suppressUnwrittenScope":false},"onChange":false,"parametersInDeclarations":true,"threads":0,"trackDependency":2,"whitelist":[]},"request":{"timeout":5000},"session":{"maxNum":10},"workspaceSymbol":{"caseSensitivity":1,"maxNum":1000,"sort":true},"xref":{"maxNum":2000}}
18:14:56 ccls           initialize.cc:323 I use -resource-dir=/usr/lib/clang/8.0.0
18:14:56 ccls           initialize.cc:356 I workspace folder: /home/yhamdoud/
18:14:56 ccls           initialize.cc:381 I start 4 indexers
18:14:56 ccls           initialize.cc:389 I dispatch initial index requests
18:14:56 ccls             pipeline.cc:478 I loaded project. Refresh semantic highlight for all working file.
18:14:56 indexer0         pipeline.cc:344 I delete /home/yhamdoud/test.c
18:14:56 preamble     sema_manager.cc:733 I create session for /home/yhamdoud/test.c
 #0 0x00007f11ea1b30bb llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/usr/lib/libLLVM-8.so+0x9f60bb)
 #1 0x00007f11ea1b0f64 llvm::sys::RunSignalHandlers() (/usr/lib/libLLVM-8.so+0x9f3f64)
 #2 0x00007f11ea1b10ee (/usr/lib/libLLVM-8.so+0x9f40ee)
 #3 0x00007f11e96033c0 __restore_rt (
/usr/lib/libpthread.so.0+0x123c0)
 #4 0x0000555bf956a237 (ccls+0x27237)
 #5 0x00007f11ea17377b (/usr/lib/libLLVM-8.so+0x9b677b)
 #6 0x0000555bf95d9822 (ccls+0x96822)
 #7 0x00007f11ee0943b1 (/usr/lib/libclangDriver.so.8+0x1233b1)
 #8 0x00007f11ee095360 (/usr/lib/libclangDriver.so.8+0x124360)
 #9 0x00007f11ee0ae015 (/usr/lib/libclangDriver.so.8+0x13d015)
#10 0x00007f11edfdfb7b clang::driver::Driver::getToolChain(llvm::opt::ArgList const&, llvm::Triple const&) const (/usr/lib/libclangDriver.so.8+0x6eb7b)
#11 0x00007f11edfeb6a4 clang::driver::Driver::BuildCompilation(llvm::ArrayRef<char const*>) (/usr/lib/libclangDriver.so.8+0x7a6a4)
#12 0x00007f11ef0397a3 clang::createInvocationFromCommandLine(llvm::ArrayRef<char const*>, llvm::IntrusiveRefCntPtr<clang::DiagnosticsEngine>, llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem>) (/usr/lib/libclangFrontend.so.8+0xc47a3)
#13 0x0000555bf9568157 (ccls+0x25157)
#14 0x0000555bf95d83b2 (ccls+0x953b2)
#15 0x00007f11e95f8a9d start_thread (/usr/lib/libpthread.so.0+0x7a9d)
#16 0x00007f11e9528b23 __GI___clone (/usr/lib/libc.so.6+0xfbb23)
[Error  - 6:14:56 PM] ccls exited with code: null
[Info  - 6:14:56 PM] Connection to server got closed. Server will restart.
18:14:56 ccls           initialize.cc:271 I initialize in directory /home/yhamdoud with uri file:///home/yhamdoud
18:14:56 ccls           initialize.cc:294 I initializationOptions: {"compilationDatabaseCommand":"","compilationDatabaseDirectory":"","cache":{"directory":".ccls-cache","format":"binary","hierarchicalPath":false,"retainInMemory":2},"capabilities":{"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"}","moreTriggerCharacter":[]},"foldingRangeProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true}}},"clang":{"excludeArgs":[],"extraArgs":[],"pathMappings":[],"resourceDir":""},"client":{"hierarchicalDocumentSymbolSupport":true,"linkSupport":true,"snippetSupport":true},"codeLens":{"localVariables":true},"completion":{"caseSensitivity":2,"detailedLabel":true,"dropOldRequests":true,"duplicateOptional":true,"filterAndSort":true,"include":{"blacklist":[],"maxPathSize":30,"suffixWhitelist":[".h",".hpp",".hh",".inc"],"whitelist":[]},"maxNum":100},"diagnostics":{"blacklist":[],"onChange":1000,"onOpen":0,"onSave":0,"spellChecking":true,"whitelist":[]},"highlight":{"largeFileSize":2097152,"lsRanges":false,"blacklist":[],"whitelist":[]},"index":{"blacklist":[],"comments":2,"initialNoLinkage":false,"initialBlacklist":[],"initialWhitelist":[],"maxInitializerLines":5,"multiVersion":0,"multiVersionBlacklist":[],"multiVersionWhitelist":[],"name":{"suppressUnwrittenScope":false},"onChange":false,"parametersInDeclarations":true,"threads":0,"trackDependency":2,"whitelist":[]},"request":{"timeout":5000},"session":{"maxNum":10},"workspaceSymbol":{"caseSensitivity":1,"maxNum":1000,"sort":true},"xref":{"maxNum":2000}}
18:14:56 ccls           initialize.cc:323 I use -resource-dir=/usr/lib/clang/8.0.0
18:14:56 ccls           initialize.cc:356 I workspace folder: /home/yhamdoud/
18:14:56 ccls           initialize.cc:381 I start 4 indexers
18:14:56 ccls           initialize.cc:389 I dispatch initial index requests
18:14:56 ccls             pipeline.cc:478 I loaded project. Refresh semantic highlight for all working file.
18:14:56 indexer1         pipeline.cc:344 I delete /home/yhamdoud/test.c
18:14:56 preamble     sema_manager.cc:733 I create session for /home/yhamdoud/test.c
 #0 0x00007f2b7fd040bb llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/usr/lib/libLLVM-8.so+0x9f60bb)
 #1
 0x00007f2b7fd01f64 llvm::sys::RunSignalHandlers() (/usr/lib/libLLVM-8.so+0x9f3f64)
 #2 0x00007f2b7fd020ee (/usr/lib/libLLVM-8.so+0x9f40ee)
 #3 0x00007f2b7f1543c0 __restore_rt (/usr/lib/libpthread.so.0+0x123c0)
 #4 0x0000562abe606237 (ccls+0x27237)
 #5 0x00007f2b7fcc477b (/usr/lib/libLLVM-8.so+0x9b677b)
 #6 0x0000562abe675822 (ccls+0x96822)
 #7 0x00007f2b83be53b1 (/usr/lib/libclangDriver.so.8+0x1233b1)
 #8 0x00007f2b83be6360 (/usr/lib/libclangDriver.so.8+0x124360)
 #9 0x00007f2b83bff015 (/usr/lib/libclangDriver.so.8+0x13d015)
#10 0x00007f2b83b30b7b clang::driver::Driver::getToolChain(llvm::opt::ArgList const&, llvm::Triple const&) const (/usr/lib/libclangDriver.so.8+0x6eb7b)
#11 0x00007f2b83b3c6a4 clang::driver::Driver::BuildCompilation(llvm::ArrayRef<char const*>) (/usr/lib/libclangDriver.so.8+0x7a6a4)
#12 0x00007f2b84b8a7a3 clang::createInvocationFromCommandLine(llvm::ArrayRef<char const*>, llvm::IntrusiveRefCntPtr<clang::DiagnosticsEngine>, llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem>) (/usr/lib/libclangFrontend.so.8+0xc47a3)
#13 0x0000562abe604157 (ccls+0x25157)
#14 0x0000562abe6743b2 (ccls+0x953b2)
#15 0x00007f2b7f149a9d start_thread (/usr/lib/libpthread.so.0+0x7a9d)
#16 0x00007f2b7f079b23 __GI___clone (/usr/lib/libc.so.6+0xfbb23)
[Error  - 6:14:56 PM] ccls exited with code: null
[Info  - 6:14:56 PM] Connection to server got closed. Server will restart.
18:14:56 ccls           initialize.cc:271 I initialize in directory /home/yhamdoud with uri file:///home/yhamdoud
18:14:56 ccls           initialize.cc:294 I initializationOptions: {"compilationDatabaseCommand":"","compilationDatabaseDirectory":"","cache":{"directory":".ccls-cache","format":"binary","hierarchicalPath":false,"retainInMemory":2},"capabilities":{"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"}","moreTriggerCharacter":[]},"foldingRangeProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true}}},"clang":{"excludeArgs":[],"extraArgs":[],"pathMappings":[],"resourceDir":""},"client":{"hierarchicalDocumentSymbolSupport":true,"linkSupport":true,"snippetSupport":true},"codeLens":{"localVariables":true},"completion":{"caseSensitivity":2,"detailedLabel":true,"dropOldRequests":true,"duplicateOptional":true,"filterAndSort":true,"include":{"blacklist":[],"maxPathSize":30,"suffixWhitelist":[".h",".hpp",".hh",".inc"],"whitelist":[]},"maxNum":100},"diagnostics":{"blacklist":[],"onChange":1000,"onOpen":0,"onSave":0,"spellChecking":true,"whitelist":[]},"highlight":{"largeFileSize":2097152,"lsRanges":false,"blacklist":[],"whitelist":[]},"index":{"blacklist":[],"comments":2,"initialNoLinkage":false,"initialBlacklist":[],"initialWhitelist":[],"maxInitializerLines":5,"multiVersion":0,"multiVersionBlacklist":[],"multiVersionWhitelist":[],"name":{"suppressUnwrittenScope":false},"onChange":false,"parametersInDeclarations":true,"threads":0,"trackDependency":2,"whitelist":[]},"request":{"timeout":5000},"session":{"maxNum":10},"workspaceSymbol":{"caseSensitivity":1,"maxNum":1000,"sort":true},"xref":{"maxNum":2000}}
18:14:56 ccls           initialize.cc:323 I use -resource-dir=/usr/lib/clang/8.0.0
18:14:56 ccls           initialize.cc:356 I workspace folder: /home/yhamdoud/
18:14:56 ccls           initialize.cc:381 I start 4 indexers
18:14:56 ccls           initialize.cc:389 I dispatch initial index requests
18:14:56 ccls             pipeline.cc:478 I loaded project. Refresh semantic highlight for all working file.
18:14:56 preamble     sema_manager.cc:733 I create session for /home/yhamdoud/test.c
18:14:56 indexer0         pipeline.cc:344 I delete /home/yhamdoud/test.c
 #0 0x00007fc597c8b0bb llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/usr/lib/libLLVM-8.so+0x9f60bb)
 #1 0x00007fc597c88f64 llvm::sys::RunSignalHandlers() (/usr/lib/libLLVM-8.so+0x9f3f64)
 #2 0x00007fc597c890ee (/usr/lib/libLLVM-8.so+0x9f40ee)
 #3 0x00007fc5970db3c0 __restore_rt (/usr/lib/libpthread.so.0+0x123c0)
 #4 0x000056391bc28237 (ccls+0x27237)
 #5
 0x00007fc597c4b77b (/usr/lib/libLLVM-8.so+0x9b677b)
 #6 0x000056391bc97822 (ccls+0x96822)
 #7 0x00007fc59bb6c3b1 (/usr/lib/libclangDriver.so.8+0x1233b1)
 #8 0x00007fc59bb6d360 (/usr/lib/libclangDriver.so.8+0x124360)
 #9 0x00007fc59bb86015 (/usr/lib/libclangDriver.so.8+0x13d015)
#10 0x00007fc59bab7b7b clang::driver::Driver::getToolChain(llvm::opt::ArgList const&, llvm::Triple const&) const (/usr/lib/libclangDriver.so.8+0x6eb7b)
#11 0x00007fc59bac36a4 clang::driver::Driver::BuildCompilation(llvm::ArrayRef<char const*>) (/usr/lib/libclangDriver.so.8+0x7a6a4)
#12 0x00007fc59cb117a3 clang::createInvocationFromCommandLine(llvm::ArrayRef<char const*>, llvm::IntrusiveRefCntPtr<clang::DiagnosticsEngine>, llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem>) (/usr/lib/libclangFrontend.so.8+0xc47a3)
#13 0x000056391bc26157 (ccls+0x25157)
#14 0x000056391bc963b2 (ccls+0x953b2)
#15 0x00007fc5970d0a9d start_thread (/usr/lib/libpthread.so.0+0x7a9d)
#16 0x00007fc597000b23 __GI___clone (/usr/lib/libc.so.6+0xfbb23)
[Error  - 6:14:57 PM] ccls exited with code: null
[Info  - 6:14:57 PM] Connection to server got closed. Server will restart.
18:14:57 ccls           initialize.cc:271 I initialize in directory /home/yhamdoud with uri file:///home/yhamdoud
18:14:57 ccls           initialize.cc:294 I initializationOptions: {"compilationDatabaseCommand":"","compilationDatabaseDirectory":"","cache":{"directory":".ccls-cache","format":"binary","hierarchicalPath":false,"retainInMemory":2},"capabilities":{"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"}","moreTriggerCharacter":[]},"foldingRangeProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true}}},"clang":{"excludeArgs":[],"extraArgs":[],"pathMappings":[],"resourceDir":""},"client":{"hierarchicalDocumentSymbolSupport":true,"linkSupport":true,"snippetSupport":true},"codeLens":{"localVariables":true},"completion":{"caseSensitivity":2,"detailedLabel":true,"dropOldRequests":true,"duplicateOptional":true,"filterAndSort":true,"include":{"blacklist":[],"maxPathSize":30,"suffixWhitelist":[".h",".hpp",".hh",".inc"],"whitelist":[]},"maxNum":100},"diagnostics":{"blacklist":[],"onChange":1000,"onOpen":0,"onSave":0,"spellChecking":true,"whitelist":[]},"highlight":{"largeFileSize":2097152,"lsRanges":false,"blacklist":[],"whitelist":[]},"index":{"blacklist":[],"comments":2,"initialNoLinkage":false,"initialBlacklist":[],"initialWhitelist":[],"maxInitializerLines":5,"multiVersion":0,"multiVersionBlacklist":[],"multiVersionWhitelist":[],"name":{"suppressUnwrittenScope":false},"onChange":false,"parametersInDeclarations":true,"threads":0,"trackDependency":2,"whitelist":[]},"request":{"timeout":5000},"session":{"maxNum":10},"workspaceSymbol":{"caseSensitivity":1,"maxNum":1000,"sort":true},"xref":{"maxNum":2000}}
18:14:57 ccls           initialize.cc:323 I use -resource-dir=/usr/lib/clang/8.0.0
18:14:57 ccls           initialize.cc:356 I workspace folder: /home/yhamdoud/
18:14:57 ccls           initialize.cc:381 I start 4 indexers
18:14:57 ccls           initialize.cc:389 I dispatch initial index requests
18:14:57 ccls             pipeline.cc:478 I loaded project. Refresh semantic highlight for all working file.
18:14:57 indexer1         pipeline.cc:344 I delete /home/yhamdoud/test.c
18:14:57 preamble     sema_manager.cc:733 I create session for /home/yhamdoud/test.c
 #0 0x00007fe3b31ac0bb llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/usr/lib/libLLVM-8.so+0x9f60bb)
 #1 0x00007fe3b31a9f64 llvm::sys::RunSignalHandlers() (/usr/lib/libLLVM-8.so+0x9f3f64)
 #2 0x00007fe3b31aa0ee (/usr/lib/libLLVM-8.so
+0x9f40ee)
 #3 0x00007fe3b25fc3c0 __restore_rt (/usr/lib/libpthread.so.0+0x123c0)
 #4 0x00005644677ba237 (ccls+0x27237)
 #5 0x00007fe3b316c77b (/usr/lib/libLLVM-8.so+0x9b677b)
 #6 0x0000564467829822 (ccls+0x96822)
 #7 0x00007fe3b708d3b1 (/usr/lib/libclangDriver.so.8+0x1233b1)
 #8 0x00007fe3b708e360 (/usr/lib/libclangDriver.so.8+0x124360)
 #9 0x00007fe3b70a7015 (/usr/lib/libclangDriver.so.8+0x13d015)
#10 0x00007fe3b6fd8b7b clang::driver::Driver::getToolChain(llvm::opt::ArgList const&, llvm::Triple const&) const (/usr/lib/libclangDriver.so.8+0x6eb7b)
#11 0x00007fe3b6fe46a4 clang::driver::Driver::BuildCompilation(llvm::ArrayRef<char const*>) (/usr/lib/libclangDriver.so.8+0x7a6a4)
#12 0x00007fe3b80327a3 clang::createInvocationFromCommandLine(llvm::ArrayRef<char const*>, llvm::IntrusiveRefCntPtr<clang::DiagnosticsEngine>, llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem>) (/usr/lib/libclangFrontend.so.8+0xc47a3)
#13 0x00005644677b8157 (ccls+0x25157)
#14 0x00005644678283b2 (ccls+0x953b2)
#15 0x00007fe3b25f1a9d start_thread (/usr/lib/libpthread.so.0+0x7a9d)
#16 0x00007fe3b2521b23 __GI___clone (/usr/lib/libc.so.6+0xfbb23)
[Error  - 6:14:57 PM] ccls exited with code: null
[Error  - 6:14:57 PM] Connection to server got closed. Server will not be restarted.

Describe the bug
The ccls server does not start.

To Reproduce

I'm using the the latest ccls version and the config from the wiki with this minimal vimrc:

vim set nocompatible set runtimepath^=/path/to/coc.nvim filetype plugin indent on syntax on set hidden
When editing a C file I get the following error:
[coc.nvim] Error output from languageserver.ccls: ccls exited with code: null

Languageserver Bug

Most helpful comment

For arch linux users who install ccls from AUR, try to modify build() in PKGBUILD

cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_CXX_COMPILER=clang++

It solves my problem.

All 11 comments

You should not try start language server in your home folder, checkout:
https://github.com/neoclide/coc.nvim/wiki/Using-workspaceFolders

You should not try start language server in your home folder, checkout:
https://github.com/neoclide/coc.nvim/wiki/Using-workspaceFolders

@chemzqm

The issue persists when I try to edit test.c with the following folder layout:
test/test.c
test/.env

(...)

19:29:53 ccls           initialize.cc:271 I initialize in directory /home/yhamdoud/test/.env with uri file:///home/yhamdoud/test/.env
19:29:53 ccls           initialize.cc:294 I initializationOptions: {"compilationDatabaseCommand":"","compilationDatabaseDirectory":"","cache":{"directory":".ccls-cache","format":"binary","hierarchicalPath":false,"retainInMemory":2},"capabilities":{"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"}","moreTriggerCharacter":[]},"foldingRangeProvider":true,"workspace":{"workspaceFolders":{"supported":true,"changeNotifications":true}}},"clang":{"excludeArgs":[],"extraArgs":[],"pathMappings":[],"resourceDir":""},"client":{"hierarchicalDocumentSymbolSupport":true,"linkSupport":true,"snippetSupport":true},"codeLens":{"localVariables":true},"completion":{"caseSensitivity":2,"detailedLabel":true,"dropOldRequests":true,"duplicateOptional":true,"filterAndSort":true,"include":{"blacklist":[],"maxPathSize":30,"suffixWhitelist":[".h",".hpp",".hh",".inc"],"whitelist":[]},"maxNum":100},"diagnostics":{"blacklist":[],"onChange":1000,"onOpen":0,"onSave":0,"spellChecking":true,"whitelist":[]},"highlight":{"largeFileSize":2097152,"lsRanges":false,"blacklist":[],"whitelist":[]},"index":{"blacklist":[],"comments":2,"initialNoLinkage":false,"initialBlacklist":[],"initialWhitelist":[],"maxInitializerLines":5,"multiVersion":0,"multiVersionBlacklist":[],"multiVersionWhitelist":[],"name":{"suppressUnwrittenScope":false},"onChange":false,"parametersInDeclarations":true,"threads":0,"trackDependency":2,"whitelist":[]},"request":{"timeout":5000},"session":{"maxNum":10},"workspaceSymbol":{"caseSensitivity":1,"maxNum":1000,"sort":true},"xref":{"maxNum":2000}}
19:29:53 ccls           initialize.cc:323 I use -resource-dir=/usr/lib/clang/8.0.0
19:29:53 ccls           initialize.cc:356 I workspace folder: /home/yhamdoud/test/.env/
19:29:53 ccls           initialize.cc:381 I start 4 indexers
19:29:53 ccls           initialize.cc:389 I dispatch initial index requests
19:29:53 indexer1         pipeline.cc:344 I delete /home/yhamdoud/test/.env/test.c
19:29:53 ccls             pipeline.cc:478 I loaded project. Refresh semantic highlight for all working file.
19:29:53 preamble     sema_manager.cc:733 I create session for /home/yhamdoud/test/.env/test.c
 #0 0x00007ffa259b80bb llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/usr/lib/libLLVM-8.so+0x9f60bb)
 #1 0x00007ffa259b5f64 llvm::sys::RunSignalHandlers() (/usr/lib/libLLVM-8.so+0x9f3f64)
 #2 0x00007ffa259b60ee (/usr/lib/libLLVM-8.so+0x9f40ee)
 #3 0x00007ffa24e083c0 __restore_rt (/usr/lib/libpthread.so.0+0x123c0)
 #4 0x000055bedcba5237 (ccls+0x27237)
 #5 0x00007ffa2597877b (/usr/lib/libLLVM-8.so+0x9b677b)
 #6 0x000055bedcc14822 (ccls+0x96822)
 #7 0x00007ffa298993b1 (/usr/lib/libclangDriver.so.8+0x1233b1)
 #8 0x00007ffa2989a360 (/usr/lib/libclangDriver.so.8+0x124360
)
 #9 0x00007ffa298b3015 (/usr/lib/libclangDriver.so.8+0x13d015)
#10 0x00007ffa297e4b7b clang::driver::Driver::getToolChain(llvm::opt::ArgList const&, llvm::Triple const&) const (/usr/lib/libclangDriver.so.8+0x6eb7b)
#11 0x00007ffa297f06a4 clang::driver::Driver::BuildCompilation(llvm::ArrayRef<char const*>) (/usr/lib/libclangDriver.so.8+0x7a6a4)
#12
 0x00007ffa2a83e7a3 clang::createInvocationFromCommandLine(llvm::ArrayRef<char const*>, llvm::IntrusiveRefCntPtr<clang::DiagnosticsEngine>, llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem>) (/usr/lib/libclangFrontend.so.8+0xc47a3)
#13 0x000055bedcba3157 (ccls+0x25157)
#14 0x000055bedcc133b2 (ccls+0x953b2)
#15 0x00007ffa24dfda9d start_thread (/usr/lib/libpthread.so.0+0x7a9d)
#16 0x00007ffa24d2db23
 __GI___clone (/usr/lib/libc.so.6+0xfbb23)
[Error  - 7:29:53 PM] Connection to server got closed. Server will not be restarted.
[Error  - 7:29:53 PM] ccls exited with code: null

No idea about the crash of ccls, can't reproduce with stable release of ccls.

Could be related with MaskRay/ccls #363?

Could be related with MaskRay/ccls #363?

Buildings with clang 8 seems to fix that problem. I've tried manually building the package but I still get the same error.

For arch linux users who install ccls from AUR, try to modify build() in PKGBUILD

cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_CXX_COMPILER=clang++

It solves my problem.

For arch linux users who install ccls from AUR, try to modify build() in PKGBUILD

cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_CXX_COMPILER=clang++

It solves my problem.

Thanks this also solves the problem on my machine. Maybe the issue is Arch-specific?

@yhamdoud I don't know, some said it's because clang has been updated to version 8. Maybe people who use other distro will also encounter this problem if they update clang.

@yhamdoud It doesn't neccesarily is Arch specific, as noted in the issue it's the problem with the default g++ compiler, it triggers Arch because we are on the bleeding-edge of updates.

For arch linux users who install ccls from AUR, try to modify build() in PKGBUILD

cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_CXX_COMPILER=clang++

It solves my problem.

Also mine. The AUR package have that fixed now.

Closing, since it's compile issue of ccls and should be fixed now.

Was this page helpful?
0 / 5 - 0 ratings