Skip to content

fix(utils): clear forceExit timer unconditionally in shutdown handler [Issue #118] - #218

Merged
Jagadeeshftw merged 1 commit into
AnchorNet-Org:mainfrom
gramseostudio-dev:feature/118-shutdown-fix
Jul 30, 2026
Merged

fix(utils): clear forceExit timer unconditionally in shutdown handler [Issue #118]#218
Jagadeeshftw merged 1 commit into
AnchorNet-Org:mainfrom
gramseostudio-dev:feature/118-shutdown-fix

Conversation

@gramseostudio-dev

Copy link
Copy Markdown
Contributor

Description

This PR resolves the issue where the forceExit timer was not being cleared unconditionally during the shutdown sequence, which could lead to unexpected forceful terminations or memory leaks.

Contributor: @gramseostudio-dev

Changes Made

  • Updated shutdown.ts to ensure the timeout timer is explicitly cleared upon a successful graceful shutdown.
  • Updated shutdown.test.ts to verify the correct timer clearing behavior.

Testing & Verification

  • Local test suite passes successfully.
  • Verified graceful shutdown sequence exits cleanly without the timer firing prematurely.
  • Ensured strict deliverable isolation (verified clean workspace with no agent/config files).

Closes #118

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.

utils/shutdown.ts createShutdownHandler never clears its forceExit timer if server.close's callback throws

2 participants