Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow passing custom name for miotdevice.set_property_by #1576

Merged
merged 2 commits into from
Nov 7, 2022

Conversation

rytilahti
Copy link
Owner

@rytilahti rytilahti commented Nov 7, 2022

This allows passing a name to use instead of the hardcoded set-{siid}-{piid} as did for miotdevice requests:

dev = MiotDevice(...)
dev.get_property_by(111, 222, 333, name="dummy-name")

will cause request did to be set to dummy_name.

{"did": "dummy-name", "siid": 111, "piid": 222, "value": 333}

Breaking change
The set_property_by's value_type is converted to keyword-only argument.

@rytilahti rytilahti merged commit 7447020 into master Nov 7, 2022
@rytilahti rytilahti deleted the feat/allow_passing_name_as_did branch November 7, 2022 21:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant