-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Description
As a maintainer I need to review and potentially perform some minor clean up how we handle server shutdown of the server instance. Technically it's a non-issue, but the potential for multiple handlers is there.
In server.ts
let sigintHandler: (() => void) | null = null;
...
const stopServer = async () => {
...
if (sigintHandler) {
process.off('SIGINT', sigintHandler);
sigintHandler = null;
}
...
if (enableSigint && !sigintHandler) {
sigintHandler = () => {
void stopServer();
};
process.on('SIGINT', sigintHandler);
Acceptance criteria
- Reviewed the potential for multiple handlers, if necessary apply patch
- Popped up in work for MCP tools should be expandable via tool-plugins #22
Metadata
Metadata
Assignees
Labels
No labels