Comments (5)
https://github.com/neoclide/coc.nvim/wiki/Debug-language-server#using-output-channel
I think the rls you're using not support this feature.
from coc-rls.
Here is the output I have captured with the Wiki technique you suggest:
[Trace - 12:08:45] Sending request 'initialize - (0)'.
Params: {
"processId": 13551,
"rootPath": "/home/iago-lito/tests/rust_test",
"rootUri": "file:///home/iago-lito/tests/rust_test",
"capabilities": {
"workspace": {
"applyEdit": true,
"workspaceEdit": {
"documentChanges": true,
"resourceOperations": [
"create",
"rename",
"delete"
],
"failureHandling": "textOnlyTransactional"
},
"didChangeConfiguration": {
"dynamicRegistration": true
},
"didChangeWatchedFiles": {
"dynamicRegistration": true
},
"symbol": {
"dynamicRegistration": true,
"symbolKind": {
"valueSet": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
19,
20,
21,
22,
23,
24,
25,
26
]
}
},
"executeCommand": {
"dynamicRegistration": true
},
"configuration": true,
"workspaceFolders": true
},
"textDocument": {
"publishDiagnostics": {
"relatedInformation": true
},
"synchronization": {
"dynamicRegistration": true,
"willSave": true,
"willSaveWaitUntil": true,
"didSave": true
},
"completion": {
"dynamicRegistration": true,
"contextSupport": true,
"completionItem": {
"snippetSupport": true,
"commitCharactersSupport": true,
"documentationFormat": [
"markdown",
"plaintext"
],
"deprecatedSupport": true,
"preselectSupport": true
},
"completionItemKind": {
"valueSet": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
19,
20,
21,
22,
23,
24,
25
]
}
},
"hover": {
"dynamicRegistration": true,
"contentFormat": [
"markdown",
"plaintext"
]
},
"signatureHelp": {
"dynamicRegistration": true,
"signatureInformation": {
"documentationFormat": [
"markdown",
"plaintext"
],
"parameterInformation": {
"labelOffsetSupport": true
}
}
},
"definition": {
"dynamicRegistration": true
},
"references": {
"dynamicRegistration": true
},
"documentHighlight": {
"dynamicRegistration": true
},
"documentSymbol": {
"dynamicRegistration": true,
"symbolKind": {
"valueSet": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
19,
20,
21,
22,
23,
24,
25,
26
]
}
},
"codeAction": {
"dynamicRegistration": true,
"codeActionLiteralSupport": {
"codeActionKind": {
"valueSet": [
"",
"quickfix",
"refactor",
"refactor.extract",
"refactor.inline",
"refactor.rewrite",
"source",
"source.organizeImports"
]
}
}
},
"codeLens": {
"dynamicRegistration": true
},
"formatting": {
"dynamicRegistration": true
},
"rangeFormatting": {
"dynamicRegistration": true
},
"onTypeFormatting": {
"dynamicRegistration": true
},
"rename": {
"dynamicRegistration": true,
"prepareSupport": true
},
"documentLink": {
"dynamicRegistration": true
},
"typeDefinition": {
"dynamicRegistration": true
},
"implementation": {
"dynamicRegistration": true
},
"declaration": {
"dynamicRegistration": true
},
"colorProvider": {
"dynamicRegistration": true
},
"foldingRange": {
"dynamicRegistration": true,
"rangeLimit": 5000,
"lineFoldingOnly": true
}
}
},
"initializationOptions": {
"omitInitBuild": true,
"cmdRun": true
},
"trace": "verbose",
"workspaceFolders": [
{
"uri": "file:///home/iago-lito/tests/rust_test",
"name": "rust_test"
}
]
}
[Trace - 12:08:45] Received response 'initialize - (0)' in 11ms.
Result: {
"capabilities": {
"textDocumentSync": 2,
"hoverProvider": true,
"completionProvider": {
"resolveProvider": true,
"triggerCharacters": [
".",
":"
]
},
"definitionProvider": true,
"implementationProvider": true,
"referencesProvider": true,
"documentHighlightProvider": true,
"documentSymbolProvider": true,
"workspaceSymbolProvider": true,
"codeActionProvider": true,
"codeLensProvider": {
"resolveProvider": false
},
"documentFormattingProvider": true,
"documentRangeFormattingProvider": false,
"renameProvider": true,
"executeCommandProvider": {
"commands": [
"rls.applySuggestion-13575",
"rls.deglobImports-13575"
]
}
}
}
[Trace - 12:08:45] Sending notification 'initialized'.
Params: {}
[Trace - 12:08:45] Sending notification 'workspace/didChangeConfiguration'.
Params: {
"settings": {
"rust": {
"clear_env_rust_log": true,
"cfg_test": false,
"unstable_features": false,
"wait_to_build": 1500,
"show_warnings": true,
"use_crate_blacklist": true,
"build_on_save": false,
"features": [],
"all_features": false,
"no_default_features": false,
"racer_completion": true,
"clippy_preference": "opt-in",
"all_targets": true,
"show_hover_context": true
}
}
}
[Trace - 12:08:45] Sending notification 'textDocument/didOpen'.
Params: {
"textDocument": {
"uri": "file:///home/iago-lito/tests/rust_test/src/main.rs",
"languageId": "rust",
"version": 1,
"text": "use std::collections::*;\n\nfn main() {\n let mut a = HashMap::new();\n let mut b = HashSet::new();\n a.insert(5, 8);\n b.insert(3);\n println!(\"{:?} {:?}\", a, b);\n}\n"
}
}
[Trace - 12:08:45] Received request 'client/registerCapability - (1)'.
Params: {
"registrations": [
{
"id": "rls-watch",
"method": "workspace/didChangeWatchedFiles",
"registerOptions": {
"watchers": [
{
"globPattern": "/home/iago-lito/tests/rust_test/Cargo.lock"
},
{
"globPattern": "/home/iago-lito/tests/rust_test/target",
"kind": 4
},
{
"globPattern": "/home/iago-lito/tests/rust_test/Cargo.toml"
}
]
}
}
]
}
[Trace - 12:08:45] Sending response 'client/registerCapability - (1)'. Processing request took 5ms
No result returned.
[Trace - 12:08:45] Received request 'client/unregisterCapability - (2)'.
Params: {
"unregisterations": [
{
"id": "rls-range-formatting",
"method": "textDocument/rangeFormatting"
}
]
}
[Trace - 12:08:45] Sending response 'client/unregisterCapability - (2)'. Processing request took 1ms
No result returned.
[Trace - 12:08:45] Received notification 'window/progress'.
Params: {
"done": null,
"id": "progress_1",
"message": null,
"percentage": null,
"title": "Building"
}
[Trace - 12:08:45] Received notification 'window/progress'.
Params: {
"done": null,
"id": "progress_1",
"message": "rust_test",
"percentage": null,
"title": "Building"
}
I can read interesting mentions of refactor.inline
or refactor.rewrite
actions, and also something related to rls.deglobImports-13575
, but I am not sure what those mean.
The rls I'm using has been installed with rustup component add rls
if I remember well.
$ rustup component list | grep rls
rls-x86_64-unknown-linux-gnu (installed)
I would be suprised if it did not feature deglob
according to this post. How can I be sure? Which rls should I use then?
from coc-rls.
Could be wrong action id.
Try :call CocActionAsync('codeAction', '')
in the line you want to run deglob
action, then checkout output channel.
from coc-rls.
This yields
[Trace - 15:00:16] Sending request 'textDocument/codeAction - (1)'.
Params: {
"textDocument": {
"uri": "file:///home/iago-lito/tests/rust_test/src/main.rs"
},
"range": {
"start": {
"line": 0,
"character": 0
},
"end": {
"line": 1,
"character": 0
}
},
"context": {
"diagnostics": []
}
}
[Trace - 15:00:16] Received response 'textDocument/codeAction - (1)' in 1ms.
Result: []
.. which looks pretty empty :\
from coc-rls.
For comparison, I have installed VSCode and deglob is available there. During execution, I can read with htop
that the same binary is being run either when I open vim or when I open VSCode, i.e.
/home/iago-lito/.rustup/toolchains/nightly-2019-04-26-x86_64-unknown-linux-gnu/bin/rls
.
Would it mean that the problem is on vim side?
from coc-rls.
Related Issues (20)
- coc-implementation doesn't work HOT 1
- Nix + macOS makes RLS fail to build HOT 1
- Suppress startup message HOT 3
- CocAction('format') using 2 spaces instead of 4 HOT 6
- Option to not to ask to install RLS? HOT 4
- rls doesnt start under cygwin vim HOT 3
- "Run Test" code lens issues bare "cargo run"
- Go to definition not working for rust stdlib HOT 2
- Fix prefix for coc-settings in the README
- Cant get autocompletion HOT 2
- NeoVim crashing on auto complete HOT 1
- Question: Is rust-analyzer engine supported? HOT 2
- Doesn't install (Timeout) HOT 1
- Conflict with existing keybindings in init.vim HOT 2
- Wondering how to activate this feature?
- Async and detect slow HOT 1
- coc-rls installation/usage without rustup? HOT 2
- how can I set tab width? HOT 1
- How to disable expandtab feature? HOT 1
- The last component of the type is always missing in floating window. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coc-rls.