Skip to content

Disabling "explicit imports code lenses" does not seem to work #438

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

Closed
edsko opened this issue Aug 16, 2021 · 5 comments
Closed

Disabling "explicit imports code lenses" does not seem to work #438

edsko opened this issue Aug 16, 2021 · 5 comments
Labels
type: question Questions about anything

Comments

@edsko
Copy link

edsko commented Aug 16, 2021

When "Enables explicit imports code lenses" is enabled, the import section of my example looks like

image

After disabling, it looks like

image

I'd not expect to see any import lenses anymore (but maybe I'm misunderstanding the setting?), but although some import lenses are gone, but all are.

I initially reported this as as a bug against HLS itself (haskell/haskell-language-server#2098) but I guess it's a vscode integration problem, not a HLS problem.

@jneira
Copy link
Member

jneira commented Aug 16, 2021

hi, thanks for the bug report, did you see haskell/haskell-language-server#2098 (comment) in the original issue?

@alanz
Copy link
Collaborator

alanz commented Aug 16, 2021

There are two import lenses, one called refine imports. I recently managed to kill it in emacs with emacs-lsp/lsp-haskell#130. The setting path is "haskell.plugin.refineImports.globalOn".

@jneira jneira added the type: question Questions about anything label Aug 16, 2021
@jneira
Copy link
Member

jneira commented Aug 18, 2021

@edsko there are two plugins emitting code lenses, you can disable last ones as suggested by @alanz

@jneira jneira closed this as completed Aug 18, 2021
@edsko
Copy link
Author

edsko commented Aug 19, 2021

Ok, great! Thanks for the responses. Just in case somebody else comes across this issue: what this means is that this particular plugin cannot (yet) be disabled using the vscode Haskell extension settings, but if you open settings.json and add

    "haskell.plugin.refineImports.globalOn": false,

the plugin is disabled.

@jneira
Copy link
Member

jneira commented Aug 19, 2021

hmm there is no config to disable it? it should

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: question Questions about anything
Projects
None yet
Development

No branches or pull requests

3 participants