From eced4eab77cf2c69d42102a2534bd7e2bafa8dfe Mon Sep 17 00:00:00 2001 From: Tristan Phease Date: Mon, 27 Apr 2026 23:10:58 +1200 Subject: [PATCH] Fix ESLint not starting on Windows (#54945) Self-Review Checklist: - [x] I've reviewed my own diff for quality, security, and reliability - [x] Unsafe blocks (if any) have justifying comments - [x] The content is consistent with the [UI/UX checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist) - [x] Tests cover the new/changed behavior - [x] Performance impact has been considered and is acceptable Closes #54093 (at least the os error 123 in the comments of that bug)/#54901 (although the diagnosis in that bug is totally wrong) Used process monitor to work out what that issue was: image There's actually a '\n' after node_modules there so it's an invalid directory. Add trim() to fix. After adding that change locally, eslint loaded fine Release Notes: - Fixed bug where eslint didn't start on Windows --- crates/project/src/lsp_store.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/project/src/lsp_store.rs b/crates/project/src/lsp_store.rs index 483f1252c4d..13d1cd90f47 100644 --- a/crates/project/src/lsp_store.rs +++ b/crates/project/src/lsp_store.rs @@ -14502,7 +14502,7 @@ impl LspAdapterDelegate for LocalLspAdapterDelegate { .output() .await?; let global_node_modules = - PathBuf::from(String::from_utf8_lossy(&output.stdout).to_string()); + PathBuf::from(String::from_utf8_lossy(&output.stdout).trim().to_string()); if let Some(version) = read_package_installed_version(global_node_modules.clone(), package_name).await?