Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

GUI v0.1.39 main process crashes: unhandled 'write EOF' at node:internal/stream_base_commons during long, output-heavy turns — Electron app restarts (Windows)

Đang mở
#925 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
45/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
electron, javascript, node.js

Hướng nghiên cứu

The crash occurs in the Electron main process during high-volume streaming output. Examine the main process logs and locate the stream write operations, likely in the agent communication or output handling code. Add error listeners to the write streams to prevent uncaught exceptions. Test by simulating a long, output-heavy agent turn in a Windows environment to verify the fix.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Summary

Trigger: long agent turns with heavy streamed output (e.g. a 135 KB file read).
Crashes within minutes, every time the turn is output-heavy.

main.log signature (%APPDATA%\Command Code\logs\main.log):
[error] [uncaughtException] Error: write EOF
at WriteWrap.onWriteComplete (node:internal/stream_base_commons:87:19)
[info] [send] turn resolved {... "stopReason":"interrupted"}
then the Electron app relaunches (no shutdown lines — hard kill).

In one log: 36 x "write EOF", 18 x uncaughtException, 34 app starts —
every error sits between "agent state: running" and an interrupted turn.
No GPU/renderer/OOM errors. Looks like an unhandled stream error event
takes down the Electron main process.

Environment: Windows · GUI v0.1.39 (packaged) · CLI reports 1.63.0.

main.log

Expected Behavior

Command Code should complete a long, output-heavy agent turn without terminating. A stream write error must be caught and handled (the app
survives it and the turn either finishes or fails gracefully with an error in the UI).

Actual Behavior

During a long turn the Electron main process hits an unhandled stream
error and the GUI dies, then restarts — mid-turn, with no shutdown lines
in the log.

Log signature (%APPDATA%\Command Code\logs\main.log), repeated on every
occurrence:

[info] [renderer] [queue] send: starting turn {...}
[info] [renderer] [queue] agent state: running {...}
... minutes pass ...
[error] [unhandled] Error: write EOF
at WriteWrap.onWriteComplete (node:internal/stream_base_commons:87:19)
[error] [uncaughtException] Error: write EOF
[info] [send] turn resolved {... "stopReason":"interrupted"}
[info] Command Code starting — v0.1.39 <- relaunch after the kill

Repro is reliable: any turn that streams a large volume (e.g. reading a
~135 KB source file into the agent) crashes within minutes. In one log
file there are 36 "write EOF" entries and 18 uncaughtExceptions across
34 app starts; there are no GPU/renderer/OOM/other error types.

My read: a write stream has no error listener; when its read end closes
mid-write, Node raises "write EOF" as an uncaughtException and the main
process is killed.

Environment: Windows · GUI v0.1.39 (packaged) · CLI reports version
1.63.0 (version mismatch may be relevant).

Steps to reproduce the issue
  1. Start Command Code GUI on Windows (v0.1.39, packaged build).
  2. Open a new conversation in any project.
  3. Ask the agent to work on a large single file so its response streams a
    large volume back — e.g. with a ~135 KB source file in the project:
    "continue refining your wireframe" (any request that makes the agent
    do full-file reads / emit large tool output works).
  4. Wait while the turn runs (no interaction needed).

Result: after a few minutes the Command Code window abruptly disappears
and relaunches. The turn is killed as "stopReason: interrupted" and no
error dialog or exit handler is shown to the user.

Frequency: reproducible on every attempt for output-heavy turns. Shorter
turns (e.g. a 39-character prompt, quick question) usually complete fine
— the crash correlates with long-running, high-volume streaming turns.

Command Code Version

1.63.0

Operating System

Windows

Terminal/IDE

Unknown

Shell

cmd.exe

Session file (optional)

No response

Fix prompt (optional)

No response

Additional context

No response

Ngôn ngữ chính
Không có dữ liệu ngôn ngữ
Star
4k
Fork
350
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của CommandCodeAI/command-code

Tất cả issue của CommandCodeAI/command-code

Issue tương tự

Thêm issue về Backend & API Design

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.