biome icon indicating copy to clipboard operation
biome copied to clipboard

🐛 Biome encountered an unexpected error

Open marmikdesai opened this issue 1 year ago • 3 comments

Environment information

2024-09-24 16:48:50.133 [info] Biome encountered an unexpected error

This is a bug in Biome, not an error in your code, and we would appreciate it if you could report it to https://github.com/biomejs/biome/issues/ along with the following information to help us fixing the issue:

Source Location: crates/biome_service/src/settings.rs:75:14
Thread Name: tokio-runtime-worker
Message: You must have at least one workspace.


2024-09-24 16:48:50.622 [info] [Error - 16:48:50] Biome language server closed

What happened?

While I start visual studio.

Expected result

It should not crash

Code of Conduct

  • [X] I agree to follow Biome's Code of Conduct

marmikdesai avatar Sep 24 '24 11:09 marmikdesai

Seeing the same issue

markmansur avatar Sep 24 '24 18:09 markmansur

To create a reproduction, you can use our new CLI tool, which should help you to create a very quick repository with what you need: npm create @biomejs/biome-reproduction

ematipico avatar Sep 27 '24 18:09 ematipico

I had this error in VSCode as well, but was able to fix:

  • remove old/bad rules from the config file that may have been removed in the last update.
  • run biome check . in project root with the project's biome.json config file included, this will cause it to throw on invalid properties.

I removed the invalid key - noDuplicateJsonKeys in my case, then restarted the LSP server and it finally went away.

hope it helps anyone else having the issue.

gnosticdev avatar Sep 28 '24 04:09 gnosticdev

Why closed? Linked issue is marked a dupe of this so this should be the canonical issue for "You must have at least one workspace".

No indication that this is always caused by invalid rules in the biome config. This is still an outstanding bug even in the pre-release (currently 2025.3.151143).

a613 avatar Mar 21 '25 20:03 a613

It was auto closed because nobody's submitted a repro yet. We can't do anything without a valid repro.

dyc3 avatar Mar 21 '25 22:03 dyc3

I had the same error as above. For me it was caused by using the latest VSCode plugin + new biome config + old biome installation.

I simply forgot to run npm install. Once I did and restarted biome - it works great.

pjamrozowicz avatar Jul 02 '25 10:07 pjamrozowicz