Version
LifeOS 7.40.4 on Windows 11 (Git for Windows shell, bun).
What is broken
Doctor.ts checks each hook file's stat.mode & 0o111 and reports not executable (chmod +x) when the bits are clear. On Windows, Node's fs.stat reports no exec bits for ordinary files, so every hook shows red although the hooks fire normally: settings.json invokes them through bun, which never consults the mode. #1992 covered the PATH-separator half of Doctor's Windows false reds; this check is the other half and still fires.
Where (file:line)
LIFEOS/TOOLS/Doctor.ts:632: if (!(mode & 0o111)) { problems.push(\${name}: not executable (chmod +x)`); continue; }`
Repro on a clean tree
- Fresh 7.40.4 install on Windows.
bun LIFEOS/TOOLS/Doctor.ts lists every hook as not executable (chmod +x).
- Start a session: the hooks fire (hook-injected context such as the Algorithm nudge and the drift reminder appears in the turn).
Negative control
bun hooks/<any>.hook.ts runs the file directly with exit 0 regardless of its mode, and the same hooks have been firing on this install since 2026-10-01 while Doctor reported them non-executable every run. The check is informative only where the file is launched as an executable, which the shipped settings.json never does.
Suggested fix
Skip the mode check when process.platform === 'win32' (the bit carries no information there), or test the interpreter line instead of the mode. Untested.
Before submitting
Version
LifeOS 7.40.4 on Windows 11 (Git for Windows shell, bun).
What is broken
Doctor.tschecks each hook file'sstat.mode & 0o111and reportsnot executable (chmod +x)when the bits are clear. On Windows, Node'sfs.statreports no exec bits for ordinary files, so every hook shows red although the hooks fire normally:settings.jsoninvokes them throughbun, which never consults the mode. #1992 covered the PATH-separator half of Doctor's Windows false reds; this check is the other half and still fires.Where (file:line)
LIFEOS/TOOLS/Doctor.ts:632:if (!(mode & 0o111)) { problems.push(\${name}: not executable (chmod +x)`); continue; }`Repro on a clean tree
bun LIFEOS/TOOLS/Doctor.tslists every hook asnot executable (chmod +x).Negative control
bun hooks/<any>.hook.tsruns the file directly with exit 0 regardless of its mode, and the same hooks have been firing on this install since 2026-10-01 while Doctor reported them non-executable every run. The check is informative only where the file is launched as an executable, which the shippedsettings.jsonnever does.Suggested fix
Skip the mode check when
process.platform === 'win32'(the bit carries no information there), or test the interpreter line instead of the mode. Untested.Before submitting