Repository navigation
Windows Desktop Start at Login writes an unquoted executable path to HKCU Run #6473
Description
Client or integration
Other — OpenCodex Desktop (Windows)
Area
Installation or packaging
Summary
OpenCodex Desktop 2.76.0 registers its Windows Start at Login entry under:
HKCU\Software\Microsoft\Windows\CurrentVersion\Run
with the executable path unquoted:
C:\Program Files\OpenCodex\opencodex-desktop.exe --autostart
Because the executable path contains spaces, I expected the registry command to quote the executable path:
"C:\Program Files\OpenCodex\opencodex-desktop.exe" --autostart
The app did still start correctly on this machine before I corrected the value manually, so this is not a confirmed startup failure in my environment. I am reporting the generated registration because an unquoted executable path containing spaces is ambiguous command-line syntax on Windows and is less robust than the quoted form.
Microsoft's CreateProcess documentation describes the ambiguity of unquoted executable paths containing spaces:
https://learn.microsoft.com/windows/win32/api/processthreadsapi/nf-processthreadsapi-createprocessw
I searched existing issues before filing. The closest related report I found is #696, but that issue concerns the older ocx tray install Run entry exceeding the 260-character limit. This report is specifically about the OpenCodex Desktop Start at Login entry and quoting of the desktop executable path.
Reproduction
- Install and launch OpenCodex Desktop 2.76.0 on Windows.
- Leave Start at Login enabled so the desktop app registers its login entry.
- Inspect the current-user Run key with PowerShell:
(Get-ItemProperty "HKCU:\Software\Microsoft\Windows\CurrentVersion\Run").OpenCodex- Observe the generated value:
C:\Program Files\OpenCodex\opencodex-desktop.exe --autostart
Win32_StartupCommandshows the same unquoted command:
Get-CimInstance Win32_StartupCommand |
Where-Object Name -eq "OpenCodex" |
Select-Object Name,CommandObserved before manual correction:
Name Command
---- -------
OpenCodex C:\Program Files\OpenCodex\opencodex-desktop.exe --autostart
- Manually changing only that Run value to the quoted form works and Windows continues to recognize the startup entry correctly:
Set-ItemProperty `
"HKCU:\Software\Microsoft\Windows\CurrentVersion\Run" `
-Name "OpenCodex" `
-Value '"C:\Program Files\OpenCodex\opencodex-desktop.exe" --autostart'Verification after the change:
Name Command
---- -------
OpenCodex "C:\Program Files\OpenCodex\opencodex-desktop.exe" --autostart
Version
OpenCodex Desktop 2.76.0
Operating system
Windows 11 x64 (exact build was not captured)
Provider and model
Not provider-specific.
Logs or error output
# Before manual correction
C:\Program Files\OpenCodex\opencodex-desktop.exe --autostart
# Expected / manually corrected value
"C:\Program Files\OpenCodex\opencodex-desktop.exe" --autostartScreenshots and supporting files
No additional files are required to reproduce this; the registry value and PowerShell commands above capture the observed behavior.
Implementation context
Current main enables Desktop login autostart through tauri-plugin-autostart (desktop/src-tauri/src/first_run.rs) and configures the login-origin argument in desktop/src-tauri/src/lib.rs. desktop/src-tauri/Cargo.toml currently pins tauri-plugin-autostart = 2.5.0.
This may ultimately be behavior in the upstream Tauri autostart plugin, but the observable packaged OpenCodex Desktop registration on Windows is the unquoted Run value above.
Checks
- I searched existing issues and documentation.
- I removed secrets, tokens, account details, request credentials, and personal data.
Activity
Ingwannu commentedon Oct 3, 2026
Thanks for separating the observed unquoted registration from a startup failure that was not reproduced. #6479 is the linked draft implementation for this Windows Desktop Start at Login case; please keep this issue open until the final patch is reviewed, Windows registration/repair behavior is verified, and the change lands on dev. A quoting source test alone is not evidence that the packaged installer upgrades an existing Run entry. I have not modified a registry entry, run Windows login startup, or treated the older tray-path issue #696 as an identical duplicate.
fix(desktop): quote Windows login executable paths (carry lidge-jun#6479
lidge-jun commentedon Oct 3, 2026
Closing this issue at the maintainer's request as part of the recovered-train cleanup. The Windows Desktop autostart executable-quoting implementation from #6479 was carried into #6487, which is merged into dev.
Final cross-platform CI passed at 7c59baf: https://github.com/lidge-jun/opencodex/actions/runs/37110109894.
Verification limit: actual Windows Start at Login and packaged-installer repair of an existing Run entry were not exercised. This closure records the landed implementation and the requested issue disposition; it does not claim those native acceptance checks passed. This updates the earlier decision to leave the issue open for that acceptance. If the updated packaged app still writes an unquoted entry, this issue can be reopened with the observed registry value.