Repository navigation
[Bug]:Linux/Hyprland: SSH environment setup fails because Electron safeStorage reports encryption unavailable #2880
Description
Activity
- addedbugSomething is broken or behaving incorrectly.Something is broken or behaving incorrectly.needs-triageIssue needs maintainer review and initial categorization.Issue needs maintainer review and initial categorization.
on May 30, 2026 - changed the title
[-][Bug]:[/-][+][Bug]:Linux/Hyprland: SSH environment setup fails because Electron safeStorage reports encryption unavailable[/+]on May 30, 2026 Confirmed on current
mainatb41e89eba9cd232cc3257b400fc30972a9b53438through the Remote link flow, so this is not limited to SSH-managed environments.Environment
- Arch Linux with Omarchy
- Hyprland on Wayland
- Electron
41.5.0 gnome-keyring-daemonis running and ownsorg.freedesktop.secrets- The user D-Bus session is available at
/run/user/1000/bus
Remote link reproduction
- Launch the desktop app from current
mainwithout a--password-storeoverride. - Open Add Environment and select Remote link.
- Enter a reachable HTTPS backend and a valid one-time pairing code.
- Select Add environment.
The remote descriptor lookup and bearer bootstrap complete, but registration fails when the desktop tries to persist the local connection catalog:
Could not register connection: ConnectionTransientError: Could not save the local connection catalog: Desktop secure storage is unavailable in this system context.This is especially disruptive for the Remote link flow because the bearer bootstrap consumes the one-time pairing code before local persistence fails.
Controlled backend probe
A minimal
safeStorageprobe using the same Electron build reports:without override backend=basic_text encryptionAvailable=false with --password-store=gnome-libsecret backend=gnome_libsecret encryptionAvailable=trueCurrent
maindoes not set apassword-storeswitch. The catalog store then correctly refuses to persist credentials through the non-encryptingbasic_textbackend.The failure therefore requires this combination:
- Electron does not recognize Hyprland for automatic Linux password-store selection
- Chromium falls back to
basic_text - T3 Code correctly fails closed for an unencrypted connection catalog
- A working Secret Service implementation is present but was not selected
The explicit
gnome-libsecretswitch is a verified workaround on this system.Suggested acceptance criteria
- On Hyprland with a working
org.freedesktop.secretsservice, Electron selects an encrypted backend and Remote link registration persists successfully. - Systems without a usable encrypted secret store continue to fail closed.
- Native backend selection on other Linux desktops, especially KDE, is not regressed.
Confirming this on Omarchy (Hyprland), using the
t3code-nightly-binAUR package (Electron-based desktop build).Same symptom, slightly different surface: pairing a remote environment failed with
Could not register connection: ConnectionTransientError: Could not save the local connection catalog: Desktop secure storage is unavailable in this system context.Confirmed Secret Service was fully functional before hitting this (
secret-tool store/lookupround-tripped fine,gnome-keyring-daemon --components=pkcs11,secretsrunning,org.freedesktop.secretsregistered on the session bus) — so this matches the report thatsafeStorage.isEncryptionAvailable()returnsfalsedespite libsecret being available, rather than an actual missing keyring.The workaround works from the outside too, not just patched into
main.ts: launching the desktop binary with the Electron switch directly resolves it:t3code-nightly --password-store=gnome-libsecretMade this permanent via a user-level
.desktopoverride (~/.local/share/applications/) adding the flag toExec=, since editing the AUR-shipped/usr/share/applications/*.desktopgets clobbered on package updates.+1 on prioritizing the Electron 42.x bump referenced above — until then, might be worth shipping the
password-store=gnome-libsecretswitch by default on Linux (as already suggested) rather than requiring users to hit this cryptic error first.Reacted by ArtrixAnother manifestation of this, and probably the most severe one: the same
basic_textfallback also breaks T3 Connect sign-in entirely — and unlike the SSH/Remote-link paths above, it doesn't fail closed with a clear error.Symptom: every sign-in method (OAuth, email code, passkey) ends with Clerk's raw API error "You are signed out". The failing request is the rotating-token exchange:
GET https://clerk.t3.codes/v1/client/sign_ins/sia_...?...&rotating_token_nonce=...&_is_native=1&_electron_sdk_version=0.0.24 → 401 {"errors":[{"code":"signed_out","long_message":"You are signed out"}]}Mechanism: with
safeStorage.isEncryptionAvailable()false,@clerk/electron's storage adapter (wired inDesktopClerk.tsviastorage({ path: stateDir })) silently drops every token write —unencryptedFallbackis not enabled, and its only diagnostic is a one-timeconsole.warnon main-process stdout, invisible unless the AppImage was launched from a terminal. Clerk rotates the client token right before the nonce exchange, the rotated token is dropped, the exchange runs unauthenticated, and FAPI answers 401signed_out.~/.t3/userdata/clerk-tokens.jsonis never created. So on a keyring-less Linux session the desktop app can't sign in at all, with no hint of the actual cause.Environment: CachyOS (Arch), Hyprland/Wayland, AppImage 0.0.32-nightly.20260803.986, Electron 41.5.0, @clerk/electron 0.0.24. No gnome-keyring; no
org.freedesktop.secretsowner.Two additions to the workaround notes in this thread:
--password-store=kwallet6also works, not justgnome-libsecret— kwalletd6 is D-Bus-activated on demand, so on a system with thekwalletpackage this needs no daemon setup, just creating a wallet on first use.- For AppImageLauncher users the flag can't live in the generated desktop entry (regenerated on every nightly); a user-owned wrapper script that globs the newest AppImage and appends the switch survives updates.
Given this now blocks sign-in (not just environment credential persistence), +1 to shipping a default
password-storeselection on Linux — and independently, the sign-in path should surface a real "no OS keyring available" error instead of Clerk's raw 401. Happy to send a PR for either.
Before submitting
Area
apps/desktop
Steps to reproduce
On Arch/Omarchy Hyprland with Electron
41.5.0, ensure Secret Service is available:gnome-keyring-daemonis runningsecret-toolworks after keyring unlockStart desktop dev mode:
Add a desktop-managed SSH environment.
Related upstream Electron issue: electron/electron#39789, fixed by electron/electron#49054. Updating Electron to a version containing that fix is likely preferred.
Expected behavior
SSH launch/tunnel succeeds and the saved environment credentials are persisted.
Actual behavior
SSH launch/tunnel succeeds, but credential persistence fails:
safeStorage.isEncryptionAvailable()returnsfalseeven though Secret Service/libsecret is available.Impact
Blocks work completely
Version or commit
No response
Environment
Arch/Omarchy Hyprland
Logs or stack traces
Screenshots, recordings, or supporting files
No response
Workaround
Until Electron is updated to
42.x, I verified this temporary workaround works inapps/desktop/src/main.ts: