Skip to content

[roborock] Fix reset of consumables - #21498

Merged
lsiepel merged 3 commits into
openhab:mainfrom
psmedley:roborock-consumables-reset
Aug 26, 2026
Merged

[roborock] Fix reset of consumables#21498
lsiepel merged 3 commits into
openhab:mainfrom
psmedley:roborock-consumables-reset

Conversation

@psmedley

Copy link
Copy Markdown
Contributor

Fixes #21461

Signed-off-by: Paul Smedley <paul@smedley.id.au>
@psmedley psmedley added the bug An unexpected problem or unintended behavior of an add-on label Aug 26, 2026
@psmedley
psmedley requested a lite review from Copilot August 26, 2026 11:43

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR targets the Roborock binding’s “Reset Consumable” command flow, aiming to fix malformed RPC parameters and align consumable identifiers with what the Roborock protocol expects (per issue #21461).

Changes:

  • Serialize the consumable-reset RPC parameter as valid JSON (string array) instead of constructing it via string concatenation.
  • Update the consumable-reset channel option values in thing-types.xml to use underscore-based identifiers (protocol format).

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
bundles/org.openhab.binding.roborock/src/main/java/org/openhab/binding/roborock/internal/RoborockVacuumHandler.java Changes how the consumable reset RPC parameter is serialized before sending.
bundles/org.openhab.binding.roborock/src/main/resources/OH-INF/thing/thing-types.xml Updates consumable-reset option values to protocol-correct underscore identifiers.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Signed-off-by: Paul Smedley <paul@smedley.id.au>
Signed-off-by: Paul Smedley <paul@smedley.id.au>

@lsiepel lsiepel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, LGTM

also for providing the test

@lsiepel
lsiepel merged commit 844711f into openhab:main Aug 26, 2026
2 checks passed
@lsiepel lsiepel added this to the 5.3 milestone Aug 26, 2026
@psmedley
psmedley deleted the roborock-consumables-reset branch August 26, 2026 20:48
psmedley added a commit to psmedley/openhab-addons that referenced this pull request Aug 28, 2026
* Fix reset of consumables

Signed-off-by: Paul Smedley <paul@smedley.id.au>
@lolodomo

Copy link
Copy Markdown
Contributor

What about backporting that fix to 5.2.x branch ?

@psmedley

Copy link
Copy Markdown
Contributor Author

What about backporting that fix to 5.2.x branch ?

I agree it should be back ported. I'd hope it could be cherry-picked.

lolodomo pushed a commit that referenced this pull request Aug 29, 2026
* Fix reset of consumables

Signed-off-by: Paul Smedley <paul@smedley.id.au>
@lolodomo

Copy link
Copy Markdown
Contributor

Backported

@lolodomo lolodomo added the backported A PR that has been cherry-picked to a patch release branch label Aug 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backported A PR that has been cherry-picked to a patch release branch bug An unexpected problem or unintended behavior of an add-on

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[roborock] Consumable reset sends malformed JSON and invalid identifiers

4 participants