Windows: the app (and its gateway) disappears mid-stream under load and never comes back
Windows: the app (and its gateway) disappears mid-stream under load and never comes back — no record left
What happened
On Windows 11 (10.0.26200), magpie was serving the local gateway at 127.0.0.1:3425 for about 20 pi sessions doing long streaming requests. At 2026-10-23 00:36:37 (local, UTC+8) the app was simply gone: the port stopped answering in the middle of several streams, every client got Connection error, and no new magpie process appeared. The gateway stayed down for ~50 minutes until I ran magpie tray; the first request then completed at 01:26:47 and everything has been fine since.
There is no crash record of any kind on this machine, and I could not reproduce it on demand, so I am reporting what is reproducible from the logs and asking what would be the best way to capture the next one.
Timeline (local, UTC+8)
| time | what |
|---|---|
| 10-22 21:55:03 | a sibling magpie web (0.1.1322) logs that the gateway on 3425 is served by another magpie 0.1.1318 |
| 23:00–00:36 | gateway handled 2,550 requests for ~20 pi sessions, peak 37 concurrent streams (00:20:01); largest request 325k input tokens |
| 00:35:54.5 | last request the gateway completed (200) |
| 00:36:23–00:36:36.9 | 12 %TEMP%\magpie-conversation-* files take their last write; nothing after that |
| 00:36:37 | pi clients: terminated, then Connection error. (00:36:39, :43, :51, 00:37:21–35) |
| 01:25:12–26 | still Connection error. (no gateway at all) |
| ~01:26 | magpie tray started; first completed request 01:26:47 |
Evidence that this was the whole process ending, not a request error
- Clients were cut mid-stream at the same instant (above), not with a 5xx.
- The gateway's own usage log (
~/.config/magpie/usage.jsonl) has all200s up to 00:35:54.5 — 190 records in 00:30–00:40, no5xx, no499— and then nothing until after the restart. - 12 in-flight conversation temp files stop being written within the same ~14 s window and are left behind (the next one is at 12:22); a normal shutdown would not leave the in-flight set like that.
127.0.0.1:3425stayed closed for the whole 50 minutes (clients still failing at 01:25).
Note: the two magpie.exe mcp image processes that stayed alive are children of the pi sessions (PPIDs are pi), not of the app, so they say nothing either way about the app's exit.
Why there is no crash record (on this machine)
- Windows Error Reporting is disabled system-wide here:
HKLM\SOFTWARE\Microsoft\Windows\Windows Error ReportinghasDisabled=1,LoggingDisabled=1.ReportArchive/ReportQueueare empty and%LOCALAPPDATA%\CrashDumpshas no magpie dump. - The Application log has no 1000 (Application Error), 1001 (WER), 1002 (Application Hang) or .NET Runtime events in the whole 24 h around the incident; nothing mentioning magpie at all. (Expected with WER off, and a Go panic/OOM writes no such event anyway.)
- magpie keeps no run/crash log that I can find:
%LOCALAPPDATA%\magpieonly hasmarket\,~/.config/magpiehas nologs/or*crash*, andmagpie --helphas nolog/doctor/versioncommand — onlymagpie heap/magpie cpufor a live process. - The app is normally started from its Start Menu shortcut (
Magpie.lnk), so there is no console for a panic trace to go to.
What it is not
No system cause: no Kernel-Power 41/42/107/109/131, no Power-Troubleshooter, no 6008/1074/6005/6006, no Resource-Exhaustion-Detector 2004, no Defender events, no reboot (LastBootUpTime 2026-10-20 14:03:23); the machine and the other processes kept running. The upstream disconnects around 23:27 and later are separate — the gateway was alive and serving around them.
Update settings (could not confirm or rule out an update restart)
settings.json has "updateEvery": 30 and "autoRestart": true (UI: Restart automatically — once an update is downloaded, restarts into it when no agent request is in flight). New releases existed at the time (0.1.1323 at 23:03, 0.1.1324 at 23:36 local), but nothing was installed at 00:36: the exe's birth/mtime did not change, last-version was not written then, and no .new file was left. The current exe was installed at 12:10 today (0.1.1330). So I can neither prove an update restart nor exclude a relaunch handshake that failed.
One oddity that may be related to the update history: the instance serving the gateway reported 0.1.1318, while the binary on disk (C:\Users\<user>\Desktop\文件\magpie.exe) was 0.1.1313 (birth 2026-10-22 00:15), and a magpie web started at 21:54 was 0.1.1322. So this machine had been running a build newer than its installed exe.
Environment
- Windows 11 Home 10.0.26200, 31.3 GB RAM.
- magpie: gateway instance 0.1.1318 at the time (see above); installed exe 0.1.1313; now 0.1.1330 (updated 2026-10-23 12:10).
- Gateway
127.0.0.1:3425; ~20pisessions, long streams; 2,550 requests in 96 minutes, peak 37 concurrent.
Possible conditions
- ~20 clients on long-lived streams, 30–40 requests/min sustained for hours, peak 37 in flight, single requests up to 325k input tokens.
- It happened about 4.5 h into that session (the gateway had been serving since at least 21:55), with no error trend before it.
- Auto-update on with 30-minute checks, and a newer release was available at the time (but nothing was installed then).
What I am asking
- Is there a way to get a panic/exit record on Windows in this setup? Would a console
magpie serverun (or redirecting stderr) be the recommended way to catch it next time, or is there a debug/log flag I missed? - Any known issue with the gateway dying under many concurrent long streams / large contexts (memory), or with the app exiting instead of restarting on an update?
- Related issues I found while checking: #2362 (macOS Update and Restart exits without relaunching), #2272 (Windows first install of an update fails), #3285 (auto-update reexec path), #2932 (panic kills the app), #2278 / #3318 (main-process memory growth).
收尾归档(我自己的报告,没拿到新证据前先关闭):当时是 magpie 0.1.1318 / Windows 11 10.0.26200 下,约 20 个 pi 会话、峰值 37 路并发流时应用与网关一起消失约 50 分钟;WER 关闭、无崩溃转储、无日志,且不能按需复现。本机现已升级到 v0.1.3853,我这边没有新的崩溃日志或稳定复现步骤可补——按「光挂着不会有结果」,先以 not planned 关闭。
若再次复现,我会带具体版本、日志与稳定复现步骤重开一个 issue;@yetone 若你希望继续追踪,也欢迎直接重开。