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

[lldb-dap] Fix: Could not find DAP in path #126903

Merged
merged 1 commit into from
Feb 13, 2025

Conversation

Da-Viper
Copy link
Contributor

Fixes #120839

@llvmbot
Copy link
Member

llvmbot commented Feb 12, 2025

@llvm/pr-subscribers-lldb

Author: None (Da-Viper)

Changes

Fixes #120839


Full diff: https://github.com/llvm/llvm-project/pull/126903.diff

1 Files Affected:

  • (modified) lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts (+2-2)
diff --git a/lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts b/lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts
index 55c2f3e9f7deb..7607053041c8c 100644
--- a/lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts
+++ b/lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts
@@ -50,13 +50,13 @@ async function findDAPExecutable(): Promise<string | undefined> {
   const executable = process.platform === "win32" ? "lldb-dap.exe" : "lldb-dap";
 
   // Prefer lldb-dap from Xcode on Darwin.
-  const xcrun_dap = findWithXcrun(executable);
+  const xcrun_dap = await findWithXcrun(executable);
   if (xcrun_dap) {
     return xcrun_dap;
   }
 
   // Find lldb-dap in the user's path.
-  const path_dap = findInPath(executable);
+  const path_dap = await findInPath(executable);
   if (path_dap) {
     return path_dap;
   }

Copy link
Member

@vogelsgesang vogelsgesang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good find! LGTM

Copy link
Member

@JDevlieghere JDevlieghere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@JDevlieghere JDevlieghere merged commit 4238238 into llvm:main Feb 13, 2025
10 checks passed
flovent pushed a commit to flovent/llvm-project that referenced this pull request Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[lldb-dap] VS Code extension does not work (Couldn't find a debug adapter descriptor)
4 participants