-
Notifications
You must be signed in to change notification settings - Fork 33
Description
Fix: Add missing dependencies for WSL2 Ubuntu
Error [ERR_SECRETS_PLATFORM_ERROR]: libsecret not available
Environment Context
- WSL version: 2.6.3.0
- Kernel version: 6.6.87.2-1
- WSLg version: 1.0.71
- MSRDC version: 1.2.6353
- Direct3D version: 1.611.1-81528511
- DXCore version: 10.0.26100.1-240331-1435.ge-release
- Windows version: 10.0.26100.7623
Distro:
- Ubuntu 24.04.3 LTS on Windows 10 x86_64
- Kernel: 6.6.87.2-microsoft-standard-WSL2
Background
When installing CodeRabbit CLI on WSL2 Ubuntu, the CLI could not store credentials securely. The official documentation does not mention the additional dependencies required on Ubuntu/WSL2.
Note: I am not a Linux expert. The commands below were adapted from ChatGPT suggestions and tested on my system.
Error Encountered
Running:
coderabbit auth login
and pasting the OAuth token results in:
CodeRabbit CLI Authentication
Please complete OAuth authentication in your browser:
1. Visit: https://app.coderabbit.ai/login?client=cli&
2. Complete the OAuth flow in your browser
3. Copy the token from your browser
Paste your Authentication Token: TOKEN
✓ OAuth callback processed
Authentication failed: unable to store credentials in secured storage with error: Error [ERR_SECRETS_PLATFORM_ERROR]: libsecret not availableFix / Workaround
Install the required dependency
sudo apt update
sudo apt install libsecret-1-0 libsecret-1-dev gnome-keyringAfter installing, restart the WSL2 distro (via wsl --shutdown or closing the terminal) and try logging in again.
Once you paste the token, you should see a prompt/window confirming that credentials are now stored successfully:
Notes
This fix is specific to WSL2 Ubuntu environments.
On other Linux distributions or native Linux, additional setup may not be necessary if libsecret is already available.