Skip to content

Close the DAVE session when the conn is discarded#568

Merged
topi314 merged 1 commit into
disgoorg:masterfrom
thomas-vilte:feat/close-dave-session
Jul 16, 2026
Merged

Close the DAVE session when the conn is discarded#568
topi314 merged 1 commit into
disgoorg:masterfrom
thomas-vilte:feat/close-dave-session

Conversation

@thomas-vilte

Copy link
Copy Markdown
Contributor

Closes #566.

Calls dave.Close() in connImpl.Close right after the gateway and udp teardown, so session implementations can stop their background work when the conn goes away for good.

I only put it in Close, not in the voice state update handler: with tryOpenGateway the conn can come back after a re-join, and the dave session has to survive that. Close is the only point where the conn is really done.

@topi314
topi314 merged commit 6298d75 into disgoorg:master Jul 16, 2026
4 checks passed
MrWong99 added a commit to MrWong99/Glyphoxa that referenced this pull request Jul 19, 2026
)

Pseudo-version at the #568 merge commit: dave.Close() in connImpl.Close — every reconnect cycle leaked a DAVE session under v0.19.6. godave v0.2.0→v0.3.0 (indirect); dave-go v0.5.1 satisfies the new Session interface (dave-tagged build+tests green). Pin comment records next deliberate-bump condition. Closes #484.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

DAVE Sessions never get closed when the conn is discarded

2 participants