cquery
cquery copied to clipboard
After recent update: lsp-timed-out-error
Debugger entered--Lisp error: (lsp-timed-out-error)
signal(lsp-timed-out-error nil)
lsp--send-wait("Content-Length: 215\15\n\15\n{"jsonrpc":"2.0","method":"$cquery/base","params":{"textDocument":{"uri":"file:///home/damon/ArchitecturePrototype/Modules/Foundation/Source/CybertronLogServer/Main.cpp"},"position":{"line":0,"character":0}},"id":2}" #
./cquery --check /home/damon/ArchitecturePrototype/Modules/Foundation/Source/CybertronLogServer/Main.cpp ( 0.000s) [main thread ] command_line.cc:438 | Running --check ( 0.000s) [main thread ] utils.cc:298 | Reading /home/damon/ArchitecturePrototype/Modules/Foundation/Source/CybertronLogServer/Main.cpp ( 0.000s) [main thread ] command_line.cc:451 | Using path /home/damon/ArchitecturePrototype/Modules/Foundation/Source/CybertronLogServer/Main.cpp ( 0.000s) [main thread ] project.cc:69 | Failed to normalize /home/damon/.cquery/bin/build ( 0.000s) [main thread ] project.cc:606 | Trying to load /home/damon/.cquery/bin/build/compile_commands.json ( 0.000s) [main thread ] project.cc:613 | Trying to load /home/damon/.cquery/bin/compile_commands.json ( 0.000s) [main thread ] project.cc:631 | Unable to load compile_commands.json located at "/home/damon/.cquery/bin/build/"; using directory listing instead. ( 0.000s) [main thread ] project.cc:504 | Using .cquery arguments from /home/damon/.cquery terminate called after throwing an instance of 'std::__ios_failure' what(): basic_filebuf::underflow error reading the file: iostream error /home/damon/.cquery/bin/../lib/libclang.so.6(+0x1919454)[0x7f42ff051454] /home/damon/.cquery/bin/../lib/libclang.so.6(+0x1919736)[0x7f42ff051736] /lib/x86_64-linux-gnu/libpthread.so.0(+0x11390)[0x7f42fca7b390] /lib/x86_64-linux-gnu/libc.so.6(gsignal+0x38)[0x7f42fc6d5428] /lib/x86_64-linux-gnu/libc.so.6(abort+0x16a)[0x7f42fc6d702a] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x8c8f7)[0x7f42fd2348f7] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x92a46)[0x7f42fd23aa46] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x92a81)[0x7f42fd23aa81] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0x92cb4)[0x7f42fd23acb4] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(_ZSt19__throw_ios_failurePKc+0x88)[0x7f42fd26bea8] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(_ZNSt13basic_filebufIcSt11char_traitsIcEE9underflowEv+0x3fa)[0x7f42fd296bba] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(_ZNSt15basic_streambufIcSt11char_traitsIcEE5uflowEv+0x26)[0x7f42fd2cb666] ./cquery(_Z11SafeGetlineRSiRNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE+0xe1)[0x5df5c1] ./cquery(_Z19ReadLinesWithEndingB5cxx11RK12AbsolutePath+0x16f)[0x5e134f] ./cquery[0x53cf30] ./cquery[0x549ebc] ./cquery(_ZN7Project4LoadERK12AbsolutePath+0x5de)[0x54b29e] ./cquery(main+0x64b)[0x465c2b] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf0)[0x7f42fc6c0830] ./cquery(_start+0x29)[0x471c39] Aborted
If i am not mistaken, cquery cannot load compile_commands.json for your project. Have you tested if this happens to another project of yours?
@innerout It should have nothing to do with this, it is random, This problem is random,sometimes it work sometimes no.But before the update, it has not appeared in the past few months.
mkdir -p build
cd build;
cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=YES ..
cd ..
ln -s build/compile_commands.json
The best thing you can do is to find a way to reproduce the bug constantly.