scalameta / metals-zed

Zed plugin for Metals
Apache License 2.0
45 stars 10 forks source link

Fix before trying to organize your imports never goes away #14

Closed razvbir closed 3 weeks ago

razvbir commented 2 months ago

image

I don't actually have any imports in that file. Is there a way to make this warning disappear after awhile?

wjoel commented 2 months ago

Zed calls codeActions all the time to be able to show them in the UI. Metals tells the client to show that message quite manually if OrganizeImports isn't available because the file has errors, so that's what Zed does: it just shows the message as it was instructed.

I think Metals should be using disabled in the response instead (which may not have existed in the LSP protocol back when OrganizeImports was first implemented), as in https://github.com/scalameta/metals/pull/6595