feat: Add a v1 protocol channel that can send messages across MQTT or Local connections, preferring local#416
Merged
allenporter merged 8 commits intoPython-roborock:mainfrom Aug 3, 2025
Conversation
Lash-L
reviewed
Aug 3, 2025
| self._callback = callback | ||
|
|
||
| # First establish MQTT connection | ||
| self._mqtt_unsub = await self._mqtt_channel.subscribe(self._on_mqtt_message) |
Collaborator
There was a problem hiding this comment.
Is it worth doing error handling here? Or are we just doing it above subscribe?
Contributor
Author
There was a problem hiding this comment.
My current thinking is to propagate to the caller. I've added pydoc explaining the expectations. (We can change, though i take your main point as it's not clear whats supposed to happen)
Collaborator
|
Sorry that took me so long - should be faster for any follow ups |
Bumps [click](https://github.com/pallets/click) from 8.1.8 to 8.2.1. - [Release notes](https://github.com/pallets/click/releases) - [Changelog](https://github.com/pallets/click/blob/main/CHANGES.rst) - [Commits](pallets/click@8.1.8...8.2.1) --- updated-dependencies: - dependency-name: click dependency-version: 8.2.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
c4b0353 to
abb2a94
Compare
Lash-L
approved these changes
Aug 3, 2025
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.
Add a V1Channel class that wraps the MQTT and Local channels and handles getting the network info from mqtt and decidign which channel is available. The local connection does not handle retries yet, which will be fixed in a follow up change.
Most of the PR is for tests exercising corner cases. This PR was heavily coded by Co-pilot.