Skip to content

Clean up event subscribers when stopping to listen to a chain#5514

Merged
bart-linera merged 1 commit intolinera-io:mainfrom
bart-linera:port-subscription-fix
Feb 25, 2026
Merged

Clean up event subscribers when stopping to listen to a chain#5514
bart-linera merged 1 commit intolinera-io:mainfrom
bart-linera:port-subscription-fix

Conversation

@bart-linera
Copy link
Copy Markdown
Contributor

Motivation

#5506 revealed a bug in the ChainListener, which is not exposed by the existing tests on main due to different handling of event subscriptions. The bug is that when the ChainListener stops listening to a chain, it doesn't remove it from the event_subscriptions map.

Proposal

Always remove a chain from event_subscriptions when no longer listening to it.

Test Plan

CI will catch regressions.

Release Plan

  • Nothing to do / These changes follow the usual release cycle.

Links

@bart-linera bart-linera requested review from afck, deuszx and ma2bd February 25, 2026 14:59
@bart-linera bart-linera marked this pull request as ready for review February 25, 2026 14:59
@bart-linera bart-linera added this pull request to the merge queue Feb 25, 2026
Merged via the queue into linera-io:main with commit d477597 Feb 25, 2026
35 of 36 checks passed
@bart-linera bart-linera deleted the port-subscription-fix branch February 25, 2026 16:52
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