Repository navigation
feat(v1): add clean_segments helper to RoomsTrait - #1081
Merged
allenporter merged 3 commits intoNov 23, 2026
Merged
allenporter merged 3 commits into
allenporter merged 3 commits into
Conversation
Starting a V1 room clean meant building the app_segment_clean payload by
hand, while Q7 and Q10 already expose clean_segments(segment_ids).
CommandTrait.clean_segments(segment_ids) sends [{"segments": segment_ids}]
and does not set a repeat count.
allenporter
requested changes
Nov 23, 2026
| """ | ||
| self._rpc_channel = None | ||
|
|
||
| async def clean_segments(self, segment_ids: list[int]) -> None: |
Contributor
There was a problem hiding this comment.
This "CommadTrait" has a single low level command send. It's meant to not have any other app logic. Can clean_segments move to another trait?
Contributor
Author
There was a problem hiding this comment.
Moved it to RoomsTrait (195448b), alongside the segment ids it takes. CommandTrait is back to just send.
CommandTrait is meant to only expose the low-level send command. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
@allenporter moved |
allenporter
approved these changes
Nov 23, 2026
Contributor
|
Thanks @hCoureau 👍 |
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.
Problem
Callers such as Home Assistant have to build the
app_segment_cleanpayload to start a room clean on a V1 vacuum. Q7 and Q10 already exposeclean_segments(segment_ids).Changes
Add
RoomsTrait.clean_segments(segment_ids)for V1. It takes the segment IDs reported by that trait and sends the V1 segment-clean command for the current map. The robot determines the cleaning order and uses its default repeat behavior.Testing
321c6d5. The default suite excludes the 11 real-broker tests.