Skip to content

Silent exit(1) of fourda.exe ~2-6 min after launch in detached/headless dev launches (pre-existing, bisected to before #498) #501

Description

@runyourempire

Symptom

target\debug\fourda.exe exits with code exactly 1, silently — no Rust panic (crash guard's default hook prints nothing with RUST_BACKTRACE=full), no Windows Event Log fault record, rotating log ends mid-flight with no RunEvent::Exit / tray-cleanup lines. Death lands 2–19 minutes after launch.

Evidence (5 reproductions, 2026-08-21, all local times UTC+10)

Run Binary Launch mode Lifetime Last log lines before death
1 #498 (f76dfb13) detached pnpm tauri dev (hidden cmd) — vite UP, webview served (eval_js worked) 337s Scoring backfill cycle scored=77
2 #498 same 195s Scoring backfill cycle scored=14 (earlier: Notification window JS never loaded — recreatingWindow destroyed label=notification)
3 #498 bare exe, no vite, RUST_BACKTRACE=full, stderr captured ~6min ACE context loaded for scoring
4 #498 bare exe via cmd wrapper capturing %ERRORLEVEL% ~19min Preemption feed cache warmed items=149TRUE_EXIT=1
5 pre-#498 (af0f1daa) same as 4 ~3min Main window shown (dev server poll fallback) / Phase 0 EXCEEDED budgetTRUE_EXIT=1

What this rules out

What it points at

Exit code exactly 1 with zero output = a deliberate process::exit(1) — the only fit found is tao's event-loop termination path on Windows (app_setup.rs notes tao process::exit()s when the loop terminates). The strongest environmental correlate: every dying run was a detached / hidden-window / console-less launch (Start-Process hidden cmd). Yesterday's interactive pnpm tauri dev sessions on the same binary class ran for hours. Runs 3–5 additionally had no vite server (webviews starved: Notification window JS never loaded, first-light budget exceeded). Suspect space: WebView2 render-process death in starved/hidden windows → window destroyed → last-window/event-loop teardown → exit(1).

Impact

  • Normal operator workflow (interactive pnpm tauri dev) appears unaffected.
  • The 30-min scheduled --engine-once refreshes are unaffected (no event loop).
  • Agent-driven detached launches for live verification are unreliable until this is understood.

Repro

Launch the debug exe hidden with no vite server (Start-Process -WindowStyle Hidden via cmd), watch it for ~5–20 min.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions