Page MenuHomePhabricator

Don't exit from the Aphlict Server prematurely
ClosedPublic

Authored by joshuaspence on Jan 19 2015, 11:00 AM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Feb 21, 2:03 PM
Unknown Object (File)
Wed, Feb 21, 1:59 PM
Unknown Object (File)
Mon, Feb 19, 5:59 PM
Unknown Object (File)
Jan 28 2024, 11:58 PM
Unknown Object (File)
Jan 26 2024, 11:16 PM
Unknown Object (File)
Jan 18 2024, 9:28 PM
Unknown Object (File)
Jan 16 2024, 1:45 AM
Unknown Object (File)
Nov 30 2023, 4:34 AM
Subscribers

Details

Reviewers
epriestley
Group Reviewers
Blessed Reviewers
Commits
Restricted Diffusion Commit
rP2b12f6160213: Don't exit from the Aphlict Server prematurely
Summary

By calling process.exit(1) we are forcing the Node.js process to exit prematurely. Specifically, the process is terminated before the error is written to the log file. This can be verified by inspecting the value of debug._logs[0]._writableState.writing immediately before the process is terminated.

Test Plan

Ran ./bin/aphlict debug without the ws module being installed. Verified that <<< UNCAUGHT EXCEPTION! >>> was echoed to the console as well as the log file. Also verified that the exit status was non-zero.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable