You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "Astro-Han (via GitHub)" <gi...@apache.org> on 2026/09/14 10:08:43 UTC
[PR] fix(desktop): resolve window presentation mode in startup context [maka]
Astro-Han opened a new pull request, #5296:
URL: https://github.com/apache/maka/pull/5296
## Summary
Refs #5194. When a workspace's stored device identity differs from its current directory, Desktop must ask whether to repair it before opening settings or starting the Runtime Host. The boot dialog introduced in #5194 reads `revealMode` before the boot module reaches its declaration, so the recovery path crashes with `Cannot access 'revealMode' before initialization` instead of displaying the question.
Resolve the process-wide reveal mode once in the existing `startup-context` module. Main startup diagnostics, startup/handoff presentation, and Runtime Host boot now consume that value. This removes the boot-local calculation and the separate `startupRevealMode()` wrapper, so window presentation no longer depends on how far asynchronous Host boot has progressed. The existing reveal policy remains responsible for active/inactive/hidden behavior. Storage identity checks and explicit repair consent are unchanged; there is no data migration or compatibility path.
## Verification
- 43 focused tests pass: startup storage repair, storage-root startup, window reveal modes, browser message boxes, startup progress, and main startup lifetime.
- The new integration test executes the boot module in source order with real storage resolution and diagnostic-dialog routing, substituting external services and the native dialog boundary. It covers cancellation without writing the marker and confirmation preserving the rootId. Restoring the previous boot-local declaration makes both cases fail with the exact reported ReferenceError.
- Real macOS Electron run against an isolated temporary profile with a deliberately stale device identity: the repair dialog was visible with the correct workspace path; dispatching its Exit button closed the app and left the marker unchanged. The installed app and real workspace were not modified.
- Workspace dependencies and overlay build pass. `npm run format`, `npm run lint`, and `git diff --check` pass.
- Desktop `build:main` is blocked by an existing TS7006 at `src/renderer/features/conversation/model/session-ui-selectors.ts:44`. Removing this PR's production changes and rebuilding at base `f32cf2b482a17f235b92e2775ed2672c2775e219` produces the same error. The emitted affected tests pass; the full Desktop typecheck is not claimed green.
## AI use
- [ ] No generative tool made a substantive contribution
- [x] Generative tooling made a substantive contribution
Tool(s) and scope: Codex — traced the regression, consolidated startup reveal policy, added and mutation-tested the regression coverage, and verified the isolated Electron dialog.
## Checklist
- [x] Tests cover the change and fail without it
- [ ] Lint, format, typecheck and the affected suites pass locally
Does this PR entail a change in behavior?
- [x] Yes — startup storage repair displays its existing confirmation instead of crashing.
- [ ] No
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org
Re: [PR] fix(desktop): resolve window presentation mode in startup context [maka]
Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han merged PR #5296:
URL: https://github.com/apache/maka/pull/5296
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org