Phase 9 of the rebrand cascade. Sweep covers everything the Phase 8
frontend pass deliberately skipped: docs/, root markdown, scripts,
Cargo.toml descriptions, code comments that survived earlier
word-boundary sed, plus a handful of identifiers caught on the final
verify pass.
transcription-app changes:
- README.md, HANDOVER.md, KNOWN-ISSUES.md, run.sh — magnotia/Magnotia
-> lumotia/Lumotia.
- docs/ — sweep across all subdirs except docs/handovers/ (preserved
as immutable audit trail). Includes architecture-map references
to magnotia_core::*, magnotia_storage::*, etc. now pointing at
lumotia_*; dev-setup.md tracing output examples (lumotia_startup
target); brief/ + superpowers/ + issues/ + whisper-ecosystem/ +
audit/.
- Cargo.toml descriptions on 9 crates (core, audio, cloud-providers,
hotkey, llm, mcp, plus referenced others).
- crates/core/src/{error,hardware,recommendation,paths}.rs +
crates/audio/src/wav.rs + crates/llm/src/model_manager.rs +
crates/cloud-providers/src/keystore.rs + crates/mcp/src/lib.rs —
doc comments and a model-manager user-agent string.
- Caught on final pass: BroadcastChannel("magnotia_task_sync") -> ...
("lumotia_task_sync"); magnotia_locale i18n localStorage key
renamed + migration shim added; CSS keyframe names
magnotiaPulse / magnotiaBar / magnotiaFade renamed in the design-
system kit; magnotia_viewer_item / magnotia_viewer_mode handoff
keys renamed in HistoryPage + viewer/+page.svelte; src/assets/
wordmark.svg text.
- src-tauri/src/lib.rs comment cleanup ("magnotia era" was sed'd
to "lumotia era" earlier — restored).
Preserved (intentional):
- crates/core/src/paths.rs — keeps "magnotia" / "Magnotia" / ".magnotia"
legacy detection strings in legacy_and_target_paths() so the
migration shim can still find user data from the magnotia era.
- src/lib/stores/{page,focusTimer}.svelte.ts + src/lib/i18n/index.ts
— migration call sites reference the legacy magnotia keys
deliberately.
- docs/handovers/ — historical audit trail.
cargo build --workspace passes. npm run check: 0 errors / 0 warnings
(3958 files). cargo test --workspace: 339 pass / 0 fail.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
55 lines
3.0 KiB
Markdown
55 lines
3.0 KiB
Markdown
# RB-08 MAJOR: PowerAssertion is a non-functional stub on macOS
|
|
|
|
**Severity:** MAJOR (macOS only)
|
|
**Path:** `src-tauri/src/commands/power.rs:41-121`
|
|
**Source:** [2026-04-22 code review](../code-review-2026-04-22.md), originally deferred during A.1 #9
|
|
**Labels:** release-blocker, major, macos, platform
|
|
|
|
**Current state (2026-04-23):** `objc2`/`objc2-foundation` have been
|
|
added behind `cfg(target_os = "macos")`, and the `NSProcessInfo`
|
|
bridge now calls `beginActivityWithOptions:reason:` / `endActivity:`
|
|
with the retained activity handle. Isolated `cargo check` validation
|
|
passes for both `x86_64-apple-darwin` and `aarch64-apple-darwin`.
|
|
Remaining acceptance gap: manual runtime verification on a real macOS
|
|
machine (`pmset -g assertions`, background live session). Diagnostic
|
|
reports now also include a `## Power assertions` section that lists any
|
|
currently active Lumotia assertion guards (`reason`, `backend`, `acquired`)
|
|
at report time, which gives the tester an in-app breadcrumb alongside
|
|
`pmset`.
|
|
|
|
## Problem
|
|
|
|
`begin_activity` always returns `Err` on macOS, so `PowerAssertion::begin` converts to `None` and the guard never acquires an `NSProcessInfo beginActivityWithOptions:reason:` assertion. Live recording and LLM cleanup therefore run without App Nap protection on the one platform where it matters.
|
|
|
|
The stub was deliberate (A.1 #9 acceptance concession — untestable on Linux without a macOS build host). Re-flagged here so it is not forgotten before the first macOS ship.
|
|
|
|
## Acceptance
|
|
|
|
- `objc2` + `objc2-foundation` deps added to the lumotia crate, gated `cfg(target_os = "macos")`.
|
|
- `begin_activity` calls `[NSProcessInfo processInfo] beginActivityWithOptions:(NSActivityUserInitiated | NSActivityLatencyCritical) reason:reason]` and retains the returned activity handle.
|
|
- `end_activity` calls `endActivity:` on the retained handle.
|
|
- Manual-test on a real macOS box: 10-minute background live session completes without throttling; `pmset -g assertions` shows Lumotia's activity during capture.
|
|
|
|
## Manual verification checklist
|
|
|
|
1. Launch Lumotia on a real macOS machine and start a live transcription session.
|
|
2. While capture is running, background the app for at least several minutes.
|
|
3. In Terminal, run `pmset -g assertions` and confirm Lumotia appears with a
|
|
user-initiated / no-idle-style assertion while the session is active.
|
|
4. While the session is still running, generate a Lumotia diagnostic report
|
|
and confirm the `## Power assertions` section lists an active entry
|
|
such as `reason=lumotia live dictation session`, `backend=macos`,
|
|
`acquired=true`.
|
|
5. Stop the session and rerun `pmset -g assertions` or regenerate the
|
|
diagnostic report to confirm the assertion disappears.
|
|
6. Repeat once for the LLM cleanup path if desired
|
|
(`reason=lumotia LLM cleanup`).
|
|
|
|
## Fix scope
|
|
|
|
Medium. Dep addition + FFI glue + manual verification. Can be done from Linux with `cargo check --target=aarch64-apple-darwin` for compile validation, but runtime behaviour needs a macOS machine.
|
|
|
|
## Dependencies
|
|
|
|
- **Hard blocker:** before first macOS build/ship.
|