scalameta / metals-vscode

Visual Studio Code extension for Metals
https://marketplace.visualstudio.com/items?itemName=scalameta.metals#overview
Apache License 2.0
298 stars 75 forks source link

failed to load ox library #1421

Closed Richie-Jang closed 1 year ago

Richie-Jang commented 1 year ago

Describe the bug

I tried to learn ox library {https://github.com/softwaremill/ox} so created sbt project and add .jvmopts file included 3 lines like --enable-preview --add-modules jdk.incubator.concurrent

Using SBT command, I can load it and run main class. But Open sbt project by Metals, I got several errors, { bloop, also sbt }

If I delete .jvmopts file in sbt project, Metals can load project without error. Could You please check this issue?

Thank you in advance. Best Regards, Richie.

Expected behavior

No response

Operating system

Windows

Editor/Extension

VS Code

Version of Metals

1.0.0+44-eb0e89b6-SNAPSHOT

Extra context or search terms

No response

tgodzik commented 1 year ago

Thanks for reporting and for not answering, it should work to do:

--enable-preview
--add-modules=jdk.incubator.concurrent

though ideally it would work also the way you described. It needs to be fixed properly in VS Code plugin

Richie-Jang commented 1 year ago

Thank you for your advice. I will try to do.