Skip to content

Add sensor platform to MadVR#121617

Merged
joostlek merged 19 commits into
home-assistant:devfrom
iloveicedgreentea:madvr_more-entities
Jul 21, 2024
Merged

Add sensor platform to MadVR#121617
joostlek merged 19 commits into
home-assistant:devfrom
iloveicedgreentea:madvr_more-entities

Conversation

@iloveicedgreentea
Copy link
Copy Markdown
Contributor

@iloveicedgreentea iloveicedgreentea commented Jul 9, 2024

Proposed change

This add sensors + tests and options flow for madvr

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New integration (thank you!)
  • New feature (which adds functionality to an existing integration)
  • Deprecation (breaking change to happen in the future)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Additional information

Checklist

  • The code change is tested and works locally.
  • Local tests pass. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist
  • I have followed the perfect PR recommendations
  • The code has been formatted using Ruff (ruff format homeassistant tests)
  • Tests have been added to verify that the new code works.

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly.
    Updated and included derived files by running: python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt.
    Updated by running python3 -m script.gen_requirements_all.
  • For the updated dependencies - a link to the changelog, or at minimum a diff between library versions is added to the PR description.

To help with the load of incoming pull requests:

@iloveicedgreentea iloveicedgreentea marked this pull request as ready for review July 9, 2024 18:43
@joostlek joostlek changed the title Madvr_more-entities Add sensor platform to MadVR Jul 9, 2024
Copy link
Copy Markdown
Member

@joostlek joostlek left a comment

Choose a reason for hiding this comment

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

Please revert the change in config_flow.py

Comment thread homeassistant/components/madvr/sensor.py Outdated
Comment thread homeassistant/components/madvr/sensor.py
Comment thread homeassistant/components/madvr/sensor.py
Comment thread homeassistant/components/madvr/sensor.py Outdated
Comment thread homeassistant/components/madvr/sensor.py Outdated
Comment thread tests/components/madvr/test_sensors.py Outdated
@home-assistant home-assistant Bot marked this pull request as draft July 9, 2024 19:00
@home-assistant
Copy link
Copy Markdown
Contributor

home-assistant Bot commented Jul 9, 2024

Please take a look at the requested changes, and use the Ready for review button when you are done, thanks 👍

Learn more about our pull request process.

@frenck
Copy link
Copy Markdown
Member

frenck commented Jul 9, 2024

Marked docs-missing as the linked PR belongs to a different parent PR. This PR does not have documentation.

@iloveicedgreentea
Copy link
Copy Markdown
Contributor Author

Updated sensors to use enums and other classes, consolidate tests into snapshot, updated the docs PR to reference this one

home-assistant/home-assistant.io#33659

@iloveicedgreentea iloveicedgreentea marked this pull request as ready for review July 9, 2024 20:18
@home-assistant home-assistant Bot requested a review from joostlek July 9, 2024 20:18
Comment thread homeassistant/components/madvr/strings.json Outdated
Comment thread tests/components/madvr/test_sensors.py Outdated
@home-assistant home-assistant Bot marked this pull request as draft July 10, 2024 09:46
@iloveicedgreentea
Copy link
Copy Markdown
Contributor Author

updated names and snapshot platform

@iloveicedgreentea iloveicedgreentea marked this pull request as ready for review July 11, 2024 02:33
@home-assistant home-assistant Bot requested a review from joostlek July 11, 2024 02:33
@iloveicedgreentea
Copy link
Copy Markdown
Contributor Author

@joostlek I updated the docs link btw should be good now

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This change is unrelated

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

its not related but makes the code a lot easier to work with

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

But it should go in a separate PR as its outside of the scope of the sensor platform

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

reverted

"integration_type": "device",
"iot_class": "local_push",
"requirements": ["py-madvr2==1.6.27"]
"requirements": ["py-madvr2==1.6.28"]
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Can we bump in a separate PR?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

no its required to fix how one of the sensors works

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

No but please bump this in a PR before this PR

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Comment thread homeassistant/components/madvr/sensor.py Outdated
Comment thread homeassistant/components/madvr/sensor.py Outdated
Comment thread tests/components/madvr/test_sensors.py Outdated
Comment thread tests/components/madvr/test_sensors.py
@home-assistant home-assistant Bot marked this pull request as draft July 20, 2024 18:42
@iloveicedgreentea iloveicedgreentea mentioned this pull request Jul 20, 2024
19 tasks
@iloveicedgreentea iloveicedgreentea marked this pull request as ready for review July 20, 2024 21:08
@home-assistant home-assistant Bot requested a review from joostlek July 20, 2024 21:08
@iloveicedgreentea
Copy link
Copy Markdown
Contributor Author

Updated doc PR: home-assistant/home-assistant.io#33896

@iloveicedgreentea
Copy link
Copy Markdown
Contributor Author

Addressed comments and updated snapshots

@joostlek joostlek merged commit fcca475 into home-assistant:dev Jul 21, 2024
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants