Skip to content

fix: prevent fatal oo-editors write EPIPE crashes#23

Merged
cs50victor merged 6 commits into
mainfrom
fix/issue-1057-handle-epipe
Apr 21, 2026
Merged

fix: prevent fatal oo-editors write EPIPE crashes#23
cs50victor merged 6 commits into
mainfrom
fix/issue-1057-handle-epipe

Conversation

@interpreterwork

@interpreterwork interpreterwork commented Apr 21, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • treat stdout/stderr EPIPE as expected stream-closure shutdown instead of fatal process crash
  • stop writing logs to a stream once that stream is known broken to prevent recursive write EPIPE loops
  • keep non-EPIPE stdio errors as fatal (exitCode=1) and continue reporting them through Sentry lifecycle hooks

Repro and Verification

Repro before fix

(FONT_DATA_DIR=/tmp/oo-fontdata PORT=39231 node oo-editors/server.js | head -n 1)

  • exit status: 1
  • output included repeated uncaught exception: Error: write EPIPE

After fix

Same command:

  • exit status: 0
  • output: startup line only, no uncaught write EPIPE

Unit tests

  • pnpm --dir oo-editors --ignore-workspace run test:unit (pass)

@cs50victor cs50victor merged commit 3add030 into main Apr 21, 2026
4 checks passed
@cs50victor cs50victor deleted the fix/issue-1057-handle-epipe branch April 21, 2026 20:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants