Windows: 3 boot-blocking bugs (fixed, commits linked) + 2 README/doctor doc gaps found verifying the README's own claims
Summary
Three real Windows boot-blocking bugs, found and fixed with a traceback and py-spy in hand (not guessed at), plus two README/code documentation gaps found while independently verifying the README's own claims against a live Windows 11 install. All three code bugs are already fixed and merged on a fork (oscampo/iai-personal-memory-engine), with commit links below for anyone hitting the same wall. Opening this mainly so the fixes are visible upstream and the doc gaps get tracked, happy to open a PR against main if that's welcome.
Environment: Windows 11, Python 3.12, iai-pme installed via pip install . from a git checkout (not the PyPI wheel).
Bug 1 — daemon crashes at boot: AttributeError: module 'signal' has no attribute 'SIGHUP'
src/iai_mcp/daemon/__init__.py, _install_boot_signal_trace(): the tuple (signal.SIGTERM, signal.SIGINT, signal.SIGHUP) was built directly in the for clause, evaluated before the inner try/except could guard it. SIGHUP doesn't exist on Windows, so this raised immediately and killed the boot, before the graceful-shutdown handlers a few lines below (which already correctly used getattr(signal, "SIGHUP", None)) ever installed.
Fix: build the signal list with the same getattr guard already used elsewhere in the same file.
Commit: oscampo/iai-personal-memory-engine@7e576682
Bug 2 — per-turn capture hook fails on every turn on Windows (rc=127)
Both copies of the capture hook (plugin/hooks/iai-mcp-turn-capture.sh and src/iai_mcp/_deploy/hooks/iai-mcp-turn-capture.sh, which must stay byte-identical per the existing "Sync the plugin hook copy" commit convention) hardcoded /usr/bin/python3, which doesn't exist under Git Bash on Windows, and unconditionally import fcntl, which is POSIX-only.
Fix: resolve IAI_MCP_PYTHON / python3 / python on PATH instead of a fixed path (fail-safe: no interpreter found → exit 0, same as any other capture failure), and replace the unconditional fcntl import with a small self-contained msvcrt.locking-based shim inside the embedded PY_SCRIPT (mirrors iai_mcp._flock, inlined because this script runs under whatever python3 resolves on PATH, not necessarily the venv where the package is installed).
Commits: oscampo/iai-personal-memory-engine@c94e996f, oscampo/iai-personal-memory-engine@b31a489b
Bug 3 — daemon boots but the socket never opens, no traceback anywhere
The real one behind the "atascado sin traceback" symptom. SocketServer.serve() (src/iai_mcp/socket_server.py) called inspect.signature(asyncio.start_unix_server) unconditionally, before the IS_WINDOWS branch further down in the same function. asyncio.start_unix_server doesn't exist on Windows, so this raised AttributeError immediately — and because serve() runs as an un-awaited asyncio.create_task() in daemon/__init__.py's main(), the exception died completely silently. The rest of the daemon (store, watchdog, queues) kept running, daemon status just said "not running", .daemon.port/.daemon.token never got created, and nothing anywhere logged a traceback. Confirmed with py-spy on a live stuck process: MainThread was idle in run_forever, not stuck mid-boot — the task had already died.
Fix: guard the inspect.signature call, plus a done_callback on mcp_socket_task that now logs any future exception at ERROR level with the full traceback and triggers normal shutdown, so a boot-time failure in the socket server can't hide behind an otherwise-healthy-looking daemon again.
Verified end to end on the real target machine after the fix: daemon status → ok: True, state: WAKE, .daemon.port/.daemon.token created; iai capture + iai recall round-tripped via daemon, not the store-direct fallback.
Commits: oscampo/iai-personal-memory-engine@1107640e, oscampo/iai-personal-memory-engine@23727ff0
Doc gap 1 — "Deployment surface" claims Unix-socket-only, false on Windows
MCP transport is a Unix domain socket. No TCP listener, no bind address, no auth surface to misconfigure.
src/iai_mcp/_ipc.py implements a TCP loopback listener (127.0.0.1:<ephemeral port>) with token auth via icacls specifically for Windows (already merged, predates 3.0.0). Confirmed live: .daemon.port and .daemon.token both exist and are in active use on a working Windows install. The "Windows: beta" badge at the top of the README doesn't cover this — the "Deployment surface" section states the Unix-socket claim as a flat, platform-unqualified fact. Loopback + token is a reasonable design, it's just not what that sentence says is happening.
Doc gap 2 — doctor table says 27 checks, the actual command runs 30
The "All 27 checks, one line each" table (under ## Doctor) lists exactly 27 rows (a–z plus +). A live iai-mcp doctor run on the same install shows three additional checks that don't appear in the table at all:
(ii) store embed identity(aa) capture-state hygiene(bb) nightly insight mint
Not a stale count, three real checks are just missing from the docs entirely.
Happy to send a PR for the doc fixes (and rebase the three Windows commits from the fork onto a clean branch against main) if that's the preferred path — let me know.
This is the most thorough of the Windows reports so far. The py-spy trace is what sold me on bug 3. A task that dies silently inside an un-awaited create_task can sit there broken for months and nothing ever tells you, and that's exactly what you caught.
Send the PR, yeah. Rebase on current main, keep the two capture-hook copies byte-identical, and keep your own commits so it stays under your name.
Put the whole boot path in it: the SIGHUP guard, the socket-server guard, the done_callback, both hook copies. You're the only one who actually confirmed the daemon reaches WAKE and round-trips via daemon after the fix, so the whole thing should land as one reviewed unit instead of getting split across reports.
The two doc gaps are already sorted on main, so you can leave those out and keep the PR to code.
Really appreciate you fixing it on your fork first and coming in with commits instead of just a repro. That's a big help, thank you.