fix(daemon): preserve run version across restart - #7500
Open
Siri-Ray wants to merge 1 commit into
Open
Conversation
PerishCode
approved these changes
Aug 27, 2026
PerishCode
left a comment
Contributor
There was a problem hiding this comment.
@Siri-Ray This preserves the run-owned application version through durable restart reconciliation while keeping legacy-state fallback explicit and preventing placeholder releases from entering PostHog or Langfuse attribution. I verified the version-resolution ordering, durable serialization and hydration path, task-level replacement telemetry, compatibility fallback, and focused regression coverage across every changed range. The implementation is carefully scoped and the restart cases are well covered—nice work closing this telemetry gap.
🔁 Powered by Looper · runner=reviewer · agent=codex · An autonomous AI dev team for your GitHub repos.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #7499
Why
Production reconciliation telemetry showed interrupted runs attributed to
app_version=0.0.0. The daemon began startup recovery before its async version cache was ready, while durable run state did not retain the version that originally started each run. This made restart outcomes look like a real0.0.0release and allowed a newer daemon version to rewrite historical run attribution.This PR preserves the run-owned version boundary without changing terminal classification, delivery idempotency, or reconciliation fences.
What users will see
There is no UI change. Interrupted runs recovered after a daemon restart now retain the Open Design version that started them in PostHog and Langfuse telemetry. Legacy run state uses the reliably resolved current version, and unresolved attribution is reported as explicit unknown or missing data rather than
0.0.0.Surface area
apps/weborapps/desktop(including Electron menu bar)odsubcommand or flag, newtools-dev/tools-packflag, or newOD_*env var/api/*endpoint, new SSE event, or changed shape inpackages/contractsskills/,design-systems/,design-templates/, orcraft/, or change to the skills protocolpackage.jsonScreenshots
Not applicable; this change has no UI surface.
Bug fix verification
apps/daemon/tests/runtimes/run-terminal-reconciliation.test.tsandapps/daemon/tests/observability/task-observation-rollout.test.tsmain: yes. The restart test failed because durable state lackedappVersionInfo; the task-observation test showedrelease,version, andmetadata.appVersionchanging from the run version0.21.1to the restarted daemon version0.22.0.Validation
pnpm exec vitest run -c vitest.config.ts tests/observability/task-observation-rollout.test.ts tests/runtimes/run-terminal-reconciliation.test.ts tests/runtimes/runs.test.ts tests/app-version.test.ts tests/runtimes/amr-terminal-reports.test.ts— 150 tests passedtests/cli-startup.test.ts— passedpnpm --filter @open-design/daemon typecheck— passedpnpm guard— passedpnpm typecheck— passed; existing landing-page hints and the local Node 24.16.0 vs declared 24.18.0 engine warning remain non-failinggit diff --check— passed