Skip to content
Strata v1.2.12

2026-05-17: Fix tauri-install loader marker race

npm run tauri:install could fail with:

❌ Post-install check failed: loader readiness marker missing in desktop log.
Expected: Backend ready — navigating to bundled frontend

even when startup actually completed.

Post-install validation in scripts/tauri-install.sh had race-prone marker logic:

  • initial one-shot check read marker too early (before it was logged), causing false failure
  • first patch switched to polling, but started scanning from the current end-of-file line
  • if marker was already logged before waiter began, polling ignored it and still false-failed
  1. Extract reusable log-wait helpers (scripts/lib/tauri-install-checks.sh).
  2. Add TDD regression script reproducing delayed and pre-existing marker cases.
  3. Pass deterministic log_lines_before snapshot captured before app launch into marker waiter.
  4. Keep strict marker-only readiness requirement.
  5. Re-run full quality gates + npm run tauri:install.
#ConventionCheck
1Documentation parity✅ Plan + release notes updates
24 test gates✅ Executed
3Plan self-review✅ This file
4Endpoint + Bruno + Swagger✅ N/A
5Bug-to-Test✅ Added automated shell regression test
6Seed isolation✅ N/A
7Transaction invariants✅ N/A
8Plan history before implementation✅ This file
9Infra test gatenpm run tauri:install
10Environment compatibility✅ macOS assumptions unchanged
11Do-no-harm baseline✅ Failure reproduced before fix, success after
12Execution summary✅ Appended below
13Doc grep rule✅ No path/command renames
14Semver release + notes✅ Completed in release section/commits

Commit: d2a62fb, a2e68e6

  • Added scripts/lib/tauri-install-checks.sh with:
    • new_logs_since_line
    • wait_for_log_marker(log_path, timeout, marker, from_line)
  • Updated scripts/tauri-install.sh:
    • capture log_lines_before before launching app
    • pass snapshot into marker wait
    • retain strict marker requirement and timeout diagnostics
  • Added scripts/test-tauri-install-marker-wait.sh regression script with two scenarios:
    • delayed marker appears after waiter starts
    • marker already present when waiter starts
  • None.
GateResult
Backend unitcd backend && npm run test:cov
Backend e2ecd backend && npm run test:e2e
Frontend unitcd front && npx vitest run --coverage
Frontend e2ecd front && npm run test:e2e
Docs buildcd docs && npm run build
Desktop install/runtimenpm run tauri:install
Script regressionbash scripts/test-tauri-install-marker-wait.sh
  • Marker polling must use a launch-time log snapshot (log_lines_before) to avoid both early-read and already-emitted-marker races.