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

Metals Server v1.0 and beyond #116

Open
mrubin opened this issue Jan 13, 2024 · 2 comments
Open

Metals Server v1.0 and beyond #116

mrubin opened this issue Jan 13, 2024 · 2 comments

Comments

@mrubin
Copy link

mrubin commented Jan 13, 2024

I'm using LSP v1.27.0 and LSP-metals v0.17.6 in Sublime Text build 4169 on Mac OS Sonoma 14.1.1.

I'm seeing the following message: "You are using Scala version 2.13.12, which is not yet supported in this version of Metals. ..." Per https://scalameta.org/metals/blog/2023/07/19/silver, there is a line of Metals versions beyond 0.11.12 - there are versions 1.0 through 1.2. Are those versions not supported through Sublime? Is there a timeframe / ETA for supporting them?

Thank you

@mrubin
Copy link
Author

mrubin commented Jan 13, 2024

Additionally, https://scalameta.org/metals/docs/editors/sublime/ states that Metals supports Scala 2.13.12.

@mrubin
Copy link
Author

mrubin commented Jan 14, 2024

For whatever it's worth, the code at this diff does not appear to be working for me. I've uninstalled LSP / LSP-metals packages, restarted Sublime, and re-installed them from scratch.. and I would consistently get Metals Server 0.11.12 locally.

I'm including a screenshot of my LSP-metals settings. Previously, the "user" settings on the right were a blank/empty JSON object ({ }). With this configuration I consistently got Metals Server 0.11.12.

Looking at the above code diff, it looks like if the server_version is set to "latest-stable", it should make a GET request to https://scalameta.org/metals/latests.json and pull out the 'release' version. When I curl this url on my machine, I get the below:

$ curl https://scalameta.org/metals/latests.json
{
  "release": "1.2.0",
  "snapshot": "1.2.0+62-0ec94060-SNAPSHOT"
}

Once I changed the "user" settings of LSP-metals to:

{
  "server_version": "1.2.0",
}

it immediately installed the expected version. It seems to me that there's a bug here somewhere.

SublimeText_LSP_metals

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

1 participant