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

[Zed Preview] Elixir language server - failed to deserialize latest release #4445

Open
1 task done
noozo opened this issue Sep 28, 2023 · 13 comments
Open
1 task done
Labels
defect [core label] elixir Elixir programming language support language server failure Language server doesn't work as expected language server An umbrella label for all language servers language An umbrella label for all programming languages syntax behaviors

Comments

@noozo
Copy link

noozo commented Sep 28, 2023

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

When updating to latest zed preview 0.106.0, got this while downloading the Elixir language server.

NOTE: Happens for both elixir-ls and the new experimental next-ls.

Language server error: Elixir

error deserializing latest release

Environment

Zed: v0.106.0 (preview)
OS: macOS 14.0.0
Memory: 16 GiB
Architecture: aarch64

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

No response

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

If you only need the most recent lines, you can run the zed: open log command palette action to see the last 1000.

No response

@noozo noozo added admin read Pending admin review defect [core label] triage Maintainer needs to classify the issue labels Sep 28, 2023
@kwando
Copy link

kwando commented Sep 28, 2023

I saw that too with next-ls but it fixed itself somehow, maybe I restarted zed or something like that. 🤷🏻

@JosephTLyons JosephTLyons added elixir Elixir programming language support language server failure Language server doesn't work as expected language server An umbrella label for all language servers language An umbrella label for all programming languages syntax behaviors and removed triage Maintainer needs to classify the issue admin read Pending admin review labels Sep 29, 2023
@arosenb2
Copy link

arosenb2 commented Oct 5, 2023

This just happened to me as well. Looks like rate limiting from Github on downloading the release.

2023-10-05T01:12:54 [INFO] starting language server "elixir-ls", path: "/**/*", id: 1
2023-10-05T01:12:54 [ERROR] Error deserializing Github API response text: "{\"message\":\"API rate limit exceeded for {redacted IPv4}. (But here's the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)\",\"documentation_url\":\"https://docs.github.com/rest/overview/resources-in-the-rest-api#rate-limiting\"}\n"

@rkusa
Copy link

rkusa commented Oct 6, 2023

Same for Rust due to rate limiting:

2023-10-06T08:50:52 [ERROR] Error deserializing Github API response text: "{\"message\":\"API rate limit exceeded for 31.19.74.205. (But here's the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)\",\"documentation_url\":\"https://docs.github.com/rest/overview/resources-in-the-rest-api#rate-limiting\"}\n"
2023-10-06T08:50:52 [ERROR] crates/zed/src/languages/rust.rs:280: no cached binary
2023-10-06T08:50:52 [ERROR] crates/language/src/language.rs:964: error deserializing latest release

@krns
Copy link

krns commented Oct 10, 2023

Same for me (elixir-ls). I see multiple occurrences of this:

2023-10-10T10:27:50 [INFO] About to spawn test binary
2023-10-10T10:27:50 [WARN] test binary failed to launch
2023-10-10T10:27:50 [WARN] test binary check failed
2023-10-10T10:27:50 [INFO] beginning to reinstall server
2023-10-10T10:27:50 [INFO] deleting server container
2023-10-10T10:27:50 [INFO] starting language server "elixir-ls", path: "/redacted-path", id: 58
2023-10-10T10:27:50 [ERROR] invalid LSP message header ""
2023-10-10T10:27:50 [ERROR] failed to start language server "elixir-ls": oneshot canceled
2023-10-10T10:27:50 [ERROR] Broken pipe (os error 32)
2023-10-10T10:27:50 [ERROR] server shut down

And finally:

2023-10-10T10:27:52 [ERROR] server shut down
2023-10-10T10:27:52 [ERROR] Broken pipe (os error 32)
2023-10-10T10:27:52 [INFO] About to spawn test binary
2023-10-10T10:27:52 [WARN] test binary failed to launch
2023-10-10T10:27:52 [WARN] test binary check failed
2023-10-10T10:27:52 [INFO] beginning to reinstall server
2023-10-10T10:27:52 [INFO] deleting server container
2023-10-10T10:27:52 [INFO] starting language server "elixir-ls", path: "/redacted-path", id: 61
2023-10-10T10:27:52 [ERROR] Error deserializing Github API response text: "{\"message\":\"API rate limit exceeded for 86.103.57.237. (But here's the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)\",\"documentation_url\":\"https://docs.github.com/rest/overview/resources-in-the-rest-api#rate-limiting\"}\n"
2023-10-10T10:27:52 [ERROR] crates/zed/src/languages/elixir.rs:301: no cached binary
2023-10-10T10:27:52 [ERROR] crates/language/src/language.rs:964: error deserializing latest release

@moomerman
Copy link
Contributor

moomerman commented Oct 11, 2023

I'm seeing the same as @krns today, I think this might be a different issue to the rate limiting since v1.17.0 was released yesterday it is likely related to that.

When I started Zed this morning I saw it was repeatedly trying to install elixir-ls, here's a snippet of the logs:

View log
2023-10-11T09:43:21 [ERROR] invalid LSP message header ""
2023-10-11T09:43:21 [ERROR] failed to start language server "elixir-ls": oneshot canceled
2023-10-11T09:43:21 [ERROR] server shut down
2023-10-11T09:43:21 [ERROR] Broken pipe (os error 32)
2023-10-11T09:43:21 [INFO] About to spawn test binary
2023-10-11T09:43:21 [WARN] test binary failed to launch
2023-10-11T09:43:21 [WARN] test binary check failed
2023-10-11T09:43:21 [INFO] beginning to reinstall server
2023-10-11T09:43:21 [INFO] deleting server container
2023-10-11T09:43:21 [INFO] starting language server "elixir-ls", path: "<redacted>", id: 7
2023-10-11T09:43:23 [ERROR] invalid LSP message header ""
2023-10-11T09:43:23 [ERROR] failed to start language server "elixir-ls": oneshot canceled
2023-10-11T09:43:23 [ERROR] Broken pipe (os error 32)
2023-10-11T09:43:23 [ERROR] server shut down
2023-10-11T09:43:23 [INFO] About to spawn test binary
2023-10-11T09:43:23 [WARN] test binary failed to launch
2023-10-11T09:43:23 [WARN] test binary check failed
2023-10-11T09:43:23 [INFO] beginning to reinstall server
2023-10-11T09:43:23 [INFO] deleting server container
2023-10-11T09:43:23 [INFO] starting language server "elixir-ls", path: "<redacted>", id: 8
2023-10-11T09:43:24 [ERROR] invalid LSP message header ""
2023-10-11T09:43:24 [ERROR] failed to start language server "elixir-ls": oneshot canceled
2023-10-11T09:43:24 [ERROR] Broken pipe (os error 32)
2023-10-11T09:43:24 [ERROR] server shut down
2023-10-11T09:43:24 [INFO] About to spawn test binary
2023-10-11T09:43:24 [WARN] test binary failed to launch
2023-10-11T09:43:24 [WARN] test binary check failed
2023-10-11T09:43:24 [INFO] beginning to reinstall server
2023-10-11T09:43:24 [INFO] deleting server container

Now I'm getting the rate limited error because it tried so many times I believe.

The logs finish with:

View log
2023-10-11T09:43:55 [ERROR] failed to start language server "elixir-ls": oneshot canceled
2023-10-11T09:43:55 [ERROR] Broken pipe (os error 32)
2023-10-11T09:43:55 [ERROR] server shut down
2023-10-11T09:43:55 [INFO] About to spawn test binary
2023-10-11T09:43:55 [WARN] test binary failed to launch
2023-10-11T09:43:55 [WARN] test binary check failed
2023-10-11T09:43:55 [INFO] beginning to reinstall server
2023-10-11T09:43:55 [INFO] deleting server container
2023-10-11T09:43:55 [INFO] starting language server "elixir-ls", path: "<redacted>", id: 31
2023-10-11T09:43:55 [ERROR] Error deserializing Github API response text: "{\"message\":\"API rate limit exceeded for 157.231.67.161. (But here's the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)\",\"documentation_url\":\"https://docs.github.com/rest/overview/resources-in-the-rest-api#rate-limiting\"}\n"
2023-10-11T09:43:55 [ERROR] crates/zed/src/languages/elixir.rs:301: no cached binary
2023-10-11T09:43:55 [ERROR] crates/language/src/language.rs:964: error deserializing latest release
2023-10-11T09:48:35 [ERROR] unexpected item event after pane was dropped
2023-10-11T09:48:38 [ERROR] oneshot canceled
2023-10-11T09:48:38 [ERROR] oneshot canceled
2023-10-11T09:48:38 [ERROR] oneshot canceled
2023-10-11T09:48:38 [ERROR] oneshot canceled

Workaround for now is to download the latest elixir-ls release somewhere on your machine and add this to your Zed settings:

"elixir": {
    "lsp": {
      "local": {
        "path": "/path/to/elixir-ls/language_server.sh",
        "arguments": [
          ""
        ]
      }
    }
  }

@joebno
Copy link

joebno commented Nov 8, 2023

I've hit rate limit issue for both elixir-ls and next-ls as well. Details:

  1. Opened a different project which uses an older version of Elixir in a new Zed window
  2. Both Zed windows raced through trying to download/install the ElixirLS
  3. Hit the rate limit.
  4. Tried with next-ls and am rate limited there as well.

MacBook Pro M1, Sonoma 14.1

Temp fix by @moomerman has at least got it working for the moment

@JosephTLyons JosephTLyons transferred this issue from zed-industries/community Jan 24, 2024
@luhc228
Copy link

luhc228 commented Jan 28, 2024

When will this issue fix? I can not develop my rust project now. @JosephTLyons

@SomeoneToIgnore
Copy link
Contributor

@luhc228 what has Rust project to do with Elixir LSP issues from 2023?
Please share more details, and if it's indeed related to Rust, in another issue.

@luhc228
Copy link

luhc228 commented Jan 28, 2024

@luhc228 what has Rust project to do with Elixir LSP issues from 2023? Please share more details, and if it's indeed related to Rust, in another issue.

I am sorry. But I think my problem is like this issue. My error is:

image

I will comment in another issue. Thanks.

@ForLoveOfCats
Copy link
Contributor

We made a change a few months ago to avoid re-attempting to install a language server too many times so I'm surprised to see we're still getting rate limited. What Zed version are you running? Did multiple language servers fail to install?

@jiangshuai1995
Copy link

image

This is my first time using zed, same error with golang.

@karelbilek
Copy link

First time using zed, having same issue with golang LSP server.

@joshrutkowski
Copy link

Working on adding an LSP and running into the same issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
defect [core label] elixir Elixir programming language support language server failure Language server doesn't work as expected language server An umbrella label for all language servers language An umbrella label for all programming languages syntax behaviors
Projects
None yet
Development

No branches or pull requests