fix: reuse one MQTT TLS session for TUI dashboard and monitor - #114
Merged
Conversation
This was referenced Aug 13, 2026
DLANSAMA
force-pushed
the
refactor/aaa-pr4-contracts
branch
from
August 13, 2026 03:32
448c320 to
0ba9c27
Compare
BambuPrinter.hold_mqtt() keeps a single paho client for status, send_command, and get_version. The TUI caches one StatusService and releases the session on quit/unmount. One-shot CLI commands still connect and tear down. Reconnect cannot re-issue a published command.
DLANSAMA
force-pushed
the
refactor/aaa-pr5-session-reuse
branch
from
August 13, 2026 03:40
100c10a to
ad7a2fa
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
AAA stack 5/9. Stacked on #113.
The TUI was opening a new MQTT TLS session on every dashboard/monitor refresh.
BambuPrinter.hold_mqtt()/release_mqtt()keep one session;MqttSessionis the reusable connection.PlateAppreleases on quit/unmount so the paho loop thread does not leak (CI runs-W error::ResourceWarning).One-shot CLI commands still connect and tear down.
Stack: #110 → #111 → #112 → #113 → this → Textual 8 / 3.10 → test stubs → sole error path → honesty