Skip to content

Conversation

@GrigoryEvko
Copy link

@GrigoryEvko GrigoryEvko commented Nov 9, 2025

Fixes memory leaks in actor lifecycle cleanup by ensuring all internal state is properly cleared when actors are stopped or complete.

Changes

  • Clear eventListeners Map in Actor._complete() and Actor._reportError()
  • Delete controllerMap entries in promise actors on XSTATE_STOP
  • Clear receivers Set and delete instanceStates entries in callback actors on XSTATE_STOP

Testing

All existing tests pass (93 test files, 2046 tests passing, 100%).

@changeset-bot
Copy link

changeset-bot bot commented Nov 9, 2025

⚠️ No Changeset found

Latest commit: 71c9c0a

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@davidkpiano davidkpiano requested a review from Andarist November 10, 2025 06:18
@davidkpiano
Copy link
Member

Nice, can you add a changeset? Just pnpm changeset and follow the instructions (patch)

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.

3 participants