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

lsp: No textDocument/inlayHint request sent to sourcekit-lsp #24183

Closed
uhooi opened this issue Jun 27, 2023 · 4 comments
Closed

lsp: No textDocument/inlayHint request sent to sourcekit-lsp #24183

uhooi opened this issue Jun 27, 2023 · 4 comments
Labels
closed:question issues that are closed as usage questions lsp

Comments

@uhooi
Copy link

uhooi commented Jun 27, 2023

Problem

SSIA
ref: swiftlang/sourcekit-lsp#757 (comment)

Steps to reproduce using "nvim -u minimal_init.lua"

require('lspconfig').sourcekit.setup()

Expected behavior

textDocument/inlayHint request is sent to sourcekit-lsp and inlay hint is displayed

Neovim version (nvim -v)

v0.10.0-dev-578+g91aeaeef6

Language server name/version

sourcekit-lsp: Included in Xcode 15.0 Beta

Operating system/version

macOS Ventura 13.3.1 (a)

Log file

https://gist.github.com/uhooi/780f9e393c77f46e459e2267b469217d

@jdrouhard
Copy link
Contributor

They aren't enabled by default. You have to use vim.lsp.buf.inlay_hint(<bufnr>) (use 0 for current buffer) to toggle them on/off. The function is likely moving to vim.lsp.inlay_hint(...) soon, though.

@justinmk justinmk closed this as not planned Won't fix, can't repro, duplicate, stale Jun 28, 2023
@justinmk justinmk added closed:question issues that are closed as usage questions and removed bug issues reporting wrong behavior labels Jun 28, 2023
@uhooi
Copy link
Author

uhooi commented Jun 29, 2023

Sorry, it showed.
I am concerned that client.supports_method('textDocument/inlayHint') is false , but it is OK.

@uhooi
Copy link
Author

uhooi commented Jun 29, 2023

I used client.server_capabilities.inlayHintProvider instead of client.supports_method('textDocument/inlayHint') and it was the same.
I think sourcekit-lsp is started after LspAttach is called.

@bryanboateng
Copy link

Where you able to solve the problem and if so how?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed:question issues that are closed as usage questions lsp
Projects
None yet
Development

No branches or pull requests

4 participants