feat: add dev/release side-by-side app identity#922
Conversation
Enable Dev and Release builds to coexist on the same machine (similar to WinUI Gallery). Debug/DevBuild=true builds get: - Display name: 'OpenClaw Companion (Dev)' / 'OpenClaw Tray (Dev)' - MSIX package identity: OpenClaw.Companion.Dev - Separate data directory: %LOCALAPPDATA%\OpenClawTray-Dev - Separate auto-start registry key: OpenClawTray-Dev - Separate single-instance mutex: OpenClawTray-Dev - Separate protocol handler: openclaw-dev:// - Separate installer AppId and install directory Add AppIdentity.cs with compile-time constants controlled by the DEV_BUILD define (auto-set for Debug configuration, or explicitly via /p:DevBuild=true). Update csproj with PatchDevAppxManifestIdentity MSBuild target that patches the MSIX manifest for dev MSIX builds. Update installer.iss to support /DDevBuild=1 preprocessor flag for producing a side-by-side dev installer. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
Codex review: needs real behavior proof before merge. Reviewed July 2, 2026, 7:05 PM ET / 23:05 UTC. Summary Reproducibility: yes. Source inspection shows the failing paths: DEV_BUILD is enabled for Debug, but SettingsManager still resolves %APPDATA%\OpenClawTray and DeepLinkParser still accepts only openclaw://. Review metrics: 1 noteworthy metric.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Mantis proof suggestion Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Land the side-by-side feature only after every identity-sensitive path is variant-aware, release defaults remain unchanged, and current-head proof shows release and dev installs running independently. Do we have a high-confidence way to reproduce the issue? Yes. Source inspection shows the failing paths: DEV_BUILD is enabled for Debug, but SettingsManager still resolves %APPDATA%\OpenClawTray and DeepLinkParser still accepts only openclaw://. Is this the best way to solve the issue? No. Centralizing identity constants is a reasonable direction, but this implementation must cover the storage, credential, parser, registry, and manifest surfaces before it is the maintainable fix. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 74604aebafef. Label changesLabel changes:
Label justifications:
Evidence reviewedSecurity concerns:
Acceptance criteria:
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
|
Hi Karen — bot review with Scott's maintainer feedback included. This is a really useful feature direction, and the central The blockers I see:
Bot-ready repair prompt you can give your coding agent: This is not a rejection of the feature. It is the right kind of feature, but the boundary is security/compatibility-sensitive, so we need it complete before merge. |
Motivation
Currently, dev and release builds of OpenClaw Companion cannot coexist on the same machine -- they share the same MSIX identity, data directory, registry keys, mutex, and protocol handler. This makes it impossible to test dev builds without disrupting a working release install (similar to how WinUI Gallery ships separate Dev and Release variants).
Approach
Introduces a compile-time
AppIdentityclass that switches all identity-sensitive constants based on aDEV_BUILDdefine. Debug builds automatically getDEV_BUILDset (or it can be forced via/p:DevBuild=true), giving them fully isolated:OpenClaw.Companion.Dev%LOCALAPPDATA%\OpenClawTray-DevOpenClawTray-DevOpenClawTray-Devopenclaw-dev://Key design decisions
#if DEV_BUILDconditional compilation rather than runtime config so the identity is baked in at compile time and cannot drift.openclaw-dev://andopenclaw://deep links for compatibility, but only registeropenclaw-dev://as their protocol handler (so they don't steal activation from release)./DDevBuild=1) to produce a completely separate installer with its own AppId, directory, mutex, and protocol registration.PatchDevAppxManifestIdentitytarget only fires whenDevBuild=trueANDWindowsPackageType=MSIX.Validation
build.ps1passes (all 5 projects)OpenClaw.Shared.Tests: 2691 passed, 31 skippedOpenClaw.Tray.Tests: 1505 passed, 0 failed