chore(startup): name the WebView2 runtime and mark every milestone

His startup.log stops after 'data dir ok', which rules out the two faults
already covered and leaves the window creation itself — where a missing
WebView2 runtime lands, sometimes as a silent exit rather than an error
anyone can print.

So the runtime's version is read from where it registers itself (both
hives, and the 32-bit view where a per-machine install usually lands) and
written BEFORE the window is attempted: 'WebView2: not found' answers the
whole question in one line. Breadcrumbs now also mark entering wails.Run,
reaching OnStartup, and the window painting — which places any launch
that produces nothing between two known points.
This commit is contained in:
2026-08-25 21:07:47 +02:00
parent ae5aa7b547
commit f3b607b15a
5 changed files with 75 additions and 2 deletions
+5
View File
@@ -994,6 +994,10 @@ func NewApp() *App { return &App{} }
func (a *App) startup(ctx context.Context) {
a.ctx = ctx
// One line in the startup log too, not only in OpsLog's own: the two
// together say whether a launch that produced no window got as far as our
// code at all, which is the fork every "it does not start" report turns on.
bootLog("OnStartup reached")
dataDir, err := userDataDir()
if err != nil {
@@ -1554,6 +1558,7 @@ func (a *App) startup(ctx context.Context) {
// it — it appears already sized and positioned, never jumping into place after
// launch. Show is unconditional: whatever happens above, the window must appear.
func (a *App) domReady(ctx context.Context) {
bootLog("OnDomReady reached — the window has painted")
a.restoreWindowPosition()
wruntime.WindowShow(ctx)
// The one number that matches what the operator actually experiences: click