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

Add duotecno OFF hvac mode #103223

Merged
merged 10 commits into from Nov 8, 2023
Merged

Conversation

Cereal2nd
Copy link
Contributor

@Cereal2nd Cereal2nd commented Nov 2, 2023

Proposed change

When implementing duotecno there is one preset that was missed, the 'off preset'

Duotecno does not allow you to control the hvac modes, these are handled internally in the modules, so the hvac modes are just to display info.
Because of this there was no way to turn the climate entity completely off, this fixes the problem by adding the OFF preset.

Users reported this problem, so it would be nice to add it to the next maintenance release.

dependancy upgrade links:
https://github.com/Cereal2nd/pyDuotecno/releases/tag/2023.11.0
https://github.com/Cereal2nd/pyDuotecno/releases/tag/2023.11.1
Cereal2nd/pyDuotecno@2023.10.1...2023.11.1

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

  • This PR fixes or closes issue: fixes #
  • This PR is related to issue:
  • Link to documentation pull request:

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 Black (black --fast 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.
  • Untested files have been added to .coveragerc.

To help with the load of incoming pull requests:

@Cereal2nd Cereal2nd marked this pull request as ready for review November 2, 2023 08:34
@Cereal2nd Cereal2nd changed the title Add the missing off preset in duotecno Duotecno climate add a missing 'OFF' preset Nov 2, 2023
@Cereal2nd Cereal2nd changed the title Duotecno climate add a missing 'OFF' preset Duotecno climate add missing 'OFF' preset Nov 2, 2023
Copy link
Member

@frenck frenck left a comment

Choose a reason for hiding this comment

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

Because of this there was no way to turn the climate entity completely off, this fixes the problem by adding the OFF preset.

This sounds like a workaround, as this will result in turning off the whole thing?
Shouldn't it be implementing the on/off services and reflect the HVAC state correctly instead?

Also, thanks for bumping the dependency! However, could you please update the PR description to contain at least one (or multiple) of the following:

  • A link to the release notes of this package version, and all versions in between.
  • A link to the changelog of this package.
  • A link to a Git(Hub) diff/compare view from the current version to the bumped version.

This allows us to review upstream changes, which is needed to decide this change is working as intended and/or if we can include it in, for example, a patch release of Home Assistant.

Thanks already! 👍

@home-assistant home-assistant bot marked this pull request as draft November 3, 2023 11:14
@home-assistant
Copy link

home-assistant bot commented Nov 3, 2023

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.

@Cereal2nd
Copy link
Contributor Author

I added the links (forgot this as this is not pure a dependancy bump PR).

Hmm not sure if i understand how we can implement the on/off state in the Climate entity

Reading this docu i can only think to get this to work woth 2 hvac modes:

  • off
  • heat_cool

but by doing it this way we lsoe the visibility if the device is heating/cooling

@Cereal2nd Cereal2nd marked this pull request as ready for review November 4, 2023 15:11
@home-assistant home-assistant bot requested a review from frenck November 4, 2023 15:11
@frenck
Copy link
Member

frenck commented Nov 4, 2023

Reading this docu i can only think to get this to work woth 2 hvac modes:

Correct, it needs to be handled via a HVAC mode, not presets as done in this PR.

@frenck frenck marked this pull request as draft November 4, 2023 16:13
@MartinHjelmare MartinHjelmare changed the title Duotecno climate add missing 'OFF' preset Add missing Duotecno climate 'OFF' preset Nov 4, 2023
@Cereal2nd Cereal2nd changed the title Add missing Duotecno climate 'OFF' preset Add duotecno hvac mode off state Nov 7, 2023
@Cereal2nd Cereal2nd changed the title Add duotecno hvac mode off state Add duotecno OFF hvac mode Nov 7, 2023
@Cereal2nd Cereal2nd marked this pull request as ready for review November 7, 2023 10:57
@frenck frenck added the smash Indicator this PR is close to finish for merging or closing label Nov 7, 2023
Copy link
Member

@frenck frenck left a comment

Choose a reason for hiding this comment

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

Thanks, @Cereal2nd 👍

../Frenck

@frenck frenck merged commit a78ef60 into home-assistant:dev Nov 8, 2023
53 checks passed
@Cereal2nd Cereal2nd deleted the duotecnoclimateoff branch November 8, 2023 11:47
@github-actions github-actions bot locked and limited conversation to collaborators Nov 9, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bugfix by-code-owner cla-signed dependency integration: duotecno Quality Scale: silver small-pr PRs with less than 30 lines. smash Indicator this PR is close to finish for merging or closing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants