Skip to content

Commit

Permalink
Merge pull request #525 from asantaga/dev
Browse files Browse the repository at this point in the history
v3.4.12
  • Loading branch information
msp1974 authored Nov 13, 2024
2 parents 49faa18 + 469e5b9 commit 43d424e
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 8 deletions.
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Wiser Home Assistant Integration v3.4.11
# Wiser Home Assistant Integration v3.4.12

[![hacs_badge](https://img.shields.io/badge/HACS-Default-orange.svg?style=for-the-badge)](https://github.com/hacs/integration)
[![downloads](https://shields.io/github/downloads/asantaga/wiserHomeAssistantPlatform/latest/total?style=for-the-badge)](https://github.com/asantaga/wiserHomeAssistantPlatform)
Expand Down Expand Up @@ -29,6 +29,15 @@ For more information checkout the AMAZING community thread available on

## Change log

- v3.4.12
- Fixed issue assigning schedules with non ascii characters in name - issue #509
- Fixed error when using HotWater climate automation - issue #517
- Fixed wiser http path not registering - issue #521
- Fixed issue causing integration to fail loading with BoilerInterface - issue #523
- Added support for ButtonPanel (Wiser Odace) - issue #524
- Bump api to v1.5.19 to resolve issues #509, #523, #524


- v3.4.11
- Bump api to v1.5.18 to reduce Payload not completed errors
- Fix typo in dimable light color mode - issue #518
Expand Down
2 changes: 1 addition & 1 deletion custom_components/wiser/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"""

VERSION = "3.4.11"
VERSION = "3.4.12"
DOMAIN = "wiser"
DATA_WISER_CONFIG = "wiser_config"
URL_BASE = "/wiser"
Expand Down
6 changes: 5 additions & 1 deletion custom_components/wiser/events.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,11 @@

def fire_events(hass: HomeAssistant, entity_id: str, old_state: dict, new_state: dict):
for event in WISER_EVENTS:
if hasattr(old_state, event[CONF_ATTRIBUTE]):
if (
hasattr(old_state, event[CONF_ATTRIBUTE])
and getattr(new_state, event[CONF_ATTRIBUTE])
and getattr(old_state, event[CONF_ATTRIBUTE])
):
if (
(
event[CONF_VALUE] == VALUE_DIFF
Expand Down
9 changes: 7 additions & 2 deletions custom_components/wiser/frontend/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@

import logging
import os
import pathlib

from homeassistant.core import HomeAssistant
from homeassistant.helpers.event import async_call_later
from homeassistant.components.http import StaticPathConfig

Expand All @@ -12,7 +14,7 @@


class WiserCardRegistration:
def __init__(self, hass):
def __init__(self, hass: HomeAssistant):
self.hass = hass

async def async_register(self):
Expand All @@ -25,7 +27,10 @@ async def async_register_wiser_path(self):
"""Register custom cards path if not already registered."""
try:
await self.hass.http.async_register_static_paths(
[StaticPathConfig(URL_BASE, "custom_components/wiser/frontend", False)]
[StaticPathConfig(URL_BASE, pathlib.Path(__file__).parent, False)]
)
_LOGGER.debug(
"Registered wiser path from %s", pathlib.Path(__file__).parent
)
except RuntimeError:
# Runtime error is likley this is already registered.
Expand Down
2 changes: 1 addition & 1 deletion custom_components/wiser/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def get_device_name(data, device_id, device_type="device"):
if device.product_type == "PowerTagE":
return f"{ENTITY_PREFIX} {device.name}"

if device.product_type == "SmokeAlarmDevice":
if device.product_type in ["SmokeAlarmDevice", "ButtonPanel"]:
device_room = data.wiserhub.rooms.get_by_id(device.room_id)
if device_room:
return f"{ENTITY_PREFIX} {device_room.name} {device.name}"
Expand Down
4 changes: 2 additions & 2 deletions custom_components/wiser/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
"iot_class": "local_polling",
"issue_tracker": "https://github.com/asantaga/wiserHomeAssistantPlatform/issues",
"requirements": [
"aioWiserHeatAPI==1.5.18"
"aioWiserHeatAPI==1.5.19"
],
"version": "3.4.10",
"version": "3.4.12",
"zeroconf": [
{
"type": "_http._tcp.local.",
Expand Down

0 comments on commit 43d424e

Please sign in to comment.