feat(api)!: rename YXWaterLevel enum values to mirror v1 values#796
Merged
Lash-L merged 1 commit intoPython-roborock:mainfrom Mar 22, 2026
Merged
feat(api)!: rename YXWaterLevel enum values to mirror v1 values#796Lash-L merged 1 commit intoPython-roborock:mainfrom
YXWaterLevel enum values to mirror v1 values#796Lash-L merged 1 commit intoPython-roborock:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the Q10 (B01 protocol) water level enum naming to better align with the v1 naming scheme, improving consistency when interpreting similar state values across device generations.
Changes:
- Renamed
YXWaterLevelenum members fromCLOSE→OFFandMIDDLE→MEDIUM(while keeping the same numeric codes). - Updated the Q10 protocol encoding test to reference
YXWaterLevel.MEDIUMinstead ofYXWaterLevel.MIDDLE.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
roborock/data/b01_q10/b01_q10_code_mappings.py |
Renames YXWaterLevel enum members to match v1 naming while preserving codes. |
tests/protocols/test_b01_q10_protocol.py |
Updates the test to use the renamed enum member. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…DDLE` to `MEDIUM`, updating a corresponding test
d5eaa89 to
383d295
Compare
lboue
approved these changes
Mar 22, 2026
Lash-L
approved these changes
Mar 22, 2026
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.
This is a small change to make the enum values slightly more consistent to make it easier to interpret q10 and v1 devices with similar state values where possible.