zed-industries / zed

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
https://zed.dev
Other
49.54k stars 3.03k forks source link

Desktop App Package (Wails.io) dIsables go lsp / disables syntax and error highlighting / terminal issues/copilot inconsistency #10253

Closed mstiles-grs closed 2 weeks ago

mstiles-grs commented 7 months ago

Check for existing issues

Describe the bug / provide steps to reproduce it

I am writing an application with Wails. I have noticed that when wails is running zed cannot use any go/terminal features. It does however work with .js/.ts/.vue files.

The following issues are holistic, due to there being so many I can't really write them in great detail. Along with that, there are no error logs present. There is no real way to show the issue I am afraid other than listing the issues. The behavior is the same across Zed stable and preview.

  1. Code actions no longer appear
  2. FMT formatting doesn't fire
  3. No error highlighting
  4. No GO LSP support
  5. Terminal does not recognize wails commands
  6. With Copilot enabled, and suggestIons turned on, no suggestions are given

The first two screenshots I am attaching shows that vue LSP and copilot are working properly. The following screenshots after shows that error highlighting/LSP/copilot suggestions are not updating/frozen.

The issues also persist after you kill the wails application. Meaning i have to force quit Zed to have it perform as expected.

Environment

M1 Mac Zed stable 0.129.2 Zed preview 0.130.1 go 1.21 wails 2.8

If applicable, add mockups / screenshots to help explain present your vision of the feature

Screenshot 2024-04-07 at 9 55 25 AM Screenshot 2024-04-07 at 9 55 38 AM

Screenshot 2024-04-07 at 9 55 50 AM Screenshot 2024-04-07 at 9 56 40 AM

Screenshot 2024-04-07 at 10 01 13 AM

If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.

No response

JosephTLyons commented 7 months ago

Hey @mstiles-grs, this issue sure is a weird one. I'm curious, what happens if you run the editor: restart language server action after runnin the walls application? Does the functionality come back at all? Also, you mentioned having issues with the terminal as well - what issues are you running into?

mstiles-grs commented 7 months ago

Hi @JosephTLyons,

I just tried running the restart command and nothing happened. I also was curious if I started another LSP, like for a different language, and nothing happens not even a log.

I just had a thought though, wails has what is essentially a live reload functionality for Go... which might be the root cause of all of these issues... The terminal inconsistency may not be as a big deal, I tried running a wails command in a vs code terminal too, and it couldn't find the wails package either.... which was the terminal inconsistency. May just be a general issue with the terminal emulator.

mstiles-grs commented 7 months ago

@JosephTLyons ,

I actually take back what I said about the terminal. I figured out how to run the wails commands in the emulated terminal (i didn't export my go path), but I think the vue LSP that zed installs messes with wails too.

The first screenshot is what I git when I run wails dev inside the terminal. However when I run it on iterm2 I get no such error.

The Go LSP is still acting the same regardless of where I run the commands.

However I also got logs (2nd & 3rd screenshot)! I'm not sure if this is unrelated to an update I just ran in zed or not, but regardless i can see the issue is that something about wails is making the golsp have a timeout error

Screenshot 2024-04-10 at 6 34 08 PM Screenshot 2024-04-10 at 7 03 47 PM

Screenshot 2024-04-10 at 7 05 58 PM

github-actions[bot] commented 1 month ago

Hi there! 👋 We're working to clean up our issue tracker by closing older issues that might not be relevant anymore. Are you able to reproduce this issue in the latest version of Zed? If so, please let us know by commenting on this issue and we will keep it open; otherwise, we'll close it in 7 days. Feel free to open a new issue if you're seeing this message after the issue has been closed. Thanks for your help!