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

Handle non-readable miot properties #1662

Merged
merged 4 commits into from
Jan 9, 2023
Merged

Conversation

rytilahti
Copy link
Owner

This PR adapts the genericmiot to expose also the defined write-only properties and converts the earlier warning to a debug message.
Suppressing the warning is likely fine, as the properties without access defined is now considered to be defined for other reasons (e.g., to define input parameters for actions).

There are (likely) two types of non-readable properties:
- Write only properties which can only be set. These are not anymore ignored but descriptors are created also for them.
- Properties without access definitions. These are likely used for action input parameter definitions, the earlier warning is converted into a debug message.
@codecov-commenter
Copy link

codecov-commenter commented Jan 9, 2023

Codecov Report

Merging #1662 (206f9ee) into master (e594007) will decrease coverage by 0.07%.
The diff coverage is 29.16%.

@@            Coverage Diff             @@
##           master    #1662      +/-   ##
==========================================
- Coverage   80.37%   80.29%   -0.08%     
==========================================
  Files         161      161              
  Lines       16047    16076      +29     
  Branches     3615     3569      -46     
==========================================
+ Hits        12897    12908      +11     
- Misses       2887     2912      +25     
+ Partials      263      256       -7     
Impacted Files Coverage Δ
miio/integrations/genericmiot/genericmiot.py 25.43% <15.38%> (-0.02%) ⬇️
miio/miot_models.py 75.28% <45.45%> (-4.34%) ⬇️
miio/devtools/__init__.py 0.00% <0.00%> (ø)
miio/devtools/pcapparser.py 0.00% <0.00%> (ø)
miio/devtools/propertytester.py 0.00% <0.00%> (ø)
miio/devtools/simulators/miiosimulator.py 0.00% <0.00%> (ø)
miio/devtools/simulators/miotsimulator.py 0.00% <0.00%> (ø)
miio/integrations/vacuum/roborock/vacuum.py 64.11% <0.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@rytilahti rytilahti merged commit 74577e4 into master Jan 9, 2023
@rytilahti rytilahti deleted the feat/genericmiot_write_onlys branch January 9, 2023 04:22
@rytilahti rytilahti mentioned this pull request Jan 9, 2023
22 tasks
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.

2 participants