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-metals treeview interferes with commands when refreshing #16

Open
julianmichael opened this issue Jun 30, 2020 · 3 comments
Open

lsp-metals treeview interferes with commands when refreshing #16

julianmichael opened this issue Jun 30, 2020 · 3 comments

Comments

@julianmichael
Copy link

julianmichael commented Jun 30, 2020

[Edited for clarity after further testing]

Describe the bug
While code is compiling and the lsp-metals treeview is refreshing with compile progress for the modules in a project, it messes with the ability to execute commands: for example, if I do a /-search (I'm in evil mode), if a refresh happens while I'm typing the query, it might shunt me into insert mode or suddenly delete the whole buffer. After this happens, commands don't work properly either, e.g., d (again in Evil normal mode) immediately deletes a whole line as if I executed dd. This may have to do with interactions with Evil mode but I'm not sure. It's hard for me to tell what the underlying problem is because it seems unpredictable. But altogether the this prevents me from doing basically anything while code is compiling.

To Reproduce
Open a scala project which takes a non-trivial amount of time to compile. Edit and save a file to trigger a compile. Then try inserting some text, executing a search within file, etc.—each refresh messes things up.

In case it matters, I'm using Spacemacs (develop) in Evil mode. So that might affect something related to the cursor movement. Idk.

Expected behavior
I expect the treeview buffer to refresh itself silently, without interfering with commands or getting the editor into weird states.

@julianmichael julianmichael changed the title lsp-metals treeview hogs the cursor when refreshing lsp-metals treeview interferes with commands when refreshing Jun 30, 2020
@kurnevsky
Copy link
Member

kurnevsky commented Jul 1, 2020

Just to clarify - it happens when your main file buffer is focused and you are editing it, right? I didn't see such problem...

Maybe @dsyzling will have an idea.

@dsyzling
Copy link
Member

dsyzling commented Jul 1, 2020

Sorry distracted with work at the moment. Since the internals of treemacs has changed and is causing issues with the metals-treeview implementation, I'm going to have try and recreate these issues once I've re-implemented on the new treemacs api. I'll also reassess some of the implementation decisions.

@julianmichael
Copy link
Author

@kurnevsky yes, that's right. As in #14, I've worked around it for now by just not using the treemacs view. Since @dsyzling is already planning changes there, we can just wait and I can update and report back after those.

For the record, I'm on emacs 26.3, Spacemacs develop (c6634203), and my .spacemacs file is here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants