Repository navigation
Description
Describe the bug
The debugger fails to detect the solana-lldb binary on certain systems where the binary is not installed in the default path being used in the extension.js file, specifically on my Arch Linux.
Lines 25 to 40 in 04e4385
| const solanalldbPath = path.join( | |
| homeDir, | |
| ".local", | |
| "share", | |
| "solana", | |
| "install", | |
| "active_release", | |
| "bin", | |
| "sdk", | |
| "sbf", | |
| "dependencies", | |
| "platform-tools", | |
| "llvm", | |
| "bin", | |
| "solana-lldb" | |
| ); |
This makes debugging impossible unless the user manually sets or symlinks the correct path.
To Reproduce
Steps to reproduce the behavior:
- Install Solana CLI and build Solana programs on a system (e.g., Arch Linux) using cargo build-sbf.
- Attempt to launch the debugger via Gimlet.
- Observe that solana-lldb is not detected, and debugging fails to initialize.
Expected behavior:
The debugger should fall back to alternative detection strategies for solana-lldb if the default path check fails, making it more robust across various development setups.
Enhance solana-lldb detection by incorporating the following fallback strategies:
- System PATH detection – Check if solana-lldb exists in the system
PATH. - Cache-based detection – Attempt to locate it within the project's
./cache/solana/directory, which is usually populated after a successfulcargo build-sbf.
These additions will make the tool more resilient to differences in Solana setup environments.
Screenshots
N/A
Environment:
- OS: Arch Linux
- Solana CLI: 2.1.20
- Rust(shipped with Agave platform tools): 1.79.0
- Rust Toolchain: stable-x86_64-unknown-linux-gnu
- Rust(my system): 1.86.0
- Extension Version: v0.0.5
- VS Code Version: 1.99.2
Additional context
On my Arch Linux setup, the current hardcoded detection strategy did not locate the binary.
However, I found solana-lldb at: ./cache/solana/<PLATFORM_TOOLS_VERSION>/platform-tools/llvm/bin/solana-lldb
Activity
failfmi commentedon Aug 15, 2025
Resolved in 0.0.9