Update elkm1_lib to 1.3.0 (#69885)

This commit is contained in:
Glenn Waters 2022-04-11 18:28:39 -04:00 committed by GitHub
parent 81d90b1bc7
commit 75fce1f036
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 7 additions and 8 deletions

View File

@ -2,7 +2,6 @@
from __future__ import annotations from __future__ import annotations
from elkm1_lib.const import AlarmState, ArmedStatus, ArmLevel, ArmUpState from elkm1_lib.const import AlarmState, ArmedStatus, ArmLevel, ArmUpState
from elkm1_lib.util import username
import voluptuous as vol import voluptuous as vol
from homeassistant.components.alarm_control_panel import ( from homeassistant.components.alarm_control_panel import (
@ -147,7 +146,7 @@ class ElkArea(ElkAttachedEntity, AlarmControlPanelEntity, RestoreEntity):
self._changed_by_keypad = keypad.name self._changed_by_keypad = keypad.name
self._changed_by_time = keypad.last_user_time.isoformat() self._changed_by_time = keypad.last_user_time.isoformat()
self._changed_by_id = keypad.last_user + 1 self._changed_by_id = keypad.last_user + 1
self._changed_by = username(self._elk, keypad.last_user) self._changed_by = self._elk.users.username(keypad.last_user)
self.async_write_ha_state() self.async_write_ha_state()
def _watch_area(self, area, changeset): def _watch_area(self, area, changeset):
@ -158,7 +157,7 @@ class ElkArea(ElkAttachedEntity, AlarmControlPanelEntity, RestoreEntity):
return return
self._changed_by_keypad = None self._changed_by_keypad = None
self._changed_by_id = last_log["user_number"] self._changed_by_id = last_log["user_number"]
self._changed_by = username(self._elk, self._changed_by_id - 1) self._changed_by = self._elk.users.username(self._changed_by_id - 1)
self._changed_by_time = last_log["timestamp"] self._changed_by_time = last_log["timestamp"]
self.async_write_ha_state() self.async_write_ha_state()

View File

@ -2,7 +2,7 @@
"domain": "elkm1", "domain": "elkm1",
"name": "Elk-M1 Control", "name": "Elk-M1 Control",
"documentation": "https://www.home-assistant.io/integrations/elkm1", "documentation": "https://www.home-assistant.io/integrations/elkm1",
"requirements": ["elkm1-lib==1.2.2"], "requirements": ["elkm1-lib==1.3.0"],
"dhcp": [{ "registered_devices": true }, { "macaddress": "00409D*" }], "dhcp": [{ "registered_devices": true }, { "macaddress": "00409D*" }],
"codeowners": ["@gwww", "@bdraco"], "codeowners": ["@gwww", "@bdraco"],
"dependencies": ["network"], "dependencies": ["network"],

View File

@ -7,7 +7,7 @@ from elkm1_lib.const import (
ZonePhysicalStatus, ZonePhysicalStatus,
ZoneType, ZoneType,
) )
from elkm1_lib.util import pretty_const, username from elkm1_lib.util import pretty_const
import voluptuous as vol import voluptuous as vol
from homeassistant.components.sensor import SensorEntity from homeassistant.components.sensor import SensorEntity
@ -155,7 +155,7 @@ class ElkKeypad(ElkSensor):
attrs["last_user_time"] = self._element.last_user_time.isoformat() attrs["last_user_time"] = self._element.last_user_time.isoformat()
attrs["last_user"] = self._element.last_user + 1 attrs["last_user"] = self._element.last_user + 1
attrs["code"] = self._element.code attrs["code"] = self._element.code
attrs["last_user_name"] = username(self._elk, self._element.last_user) attrs["last_user_name"] = self._elk.users.username(self._element.last_user)
attrs["last_keypress"] = self._element.last_keypress attrs["last_keypress"] = self._element.last_keypress
return attrs return attrs

View File

@ -578,7 +578,7 @@ elgato==3.0.0
eliqonline==1.2.2 eliqonline==1.2.2
# homeassistant.components.elkm1 # homeassistant.components.elkm1
elkm1-lib==1.2.2 elkm1-lib==1.3.0
# homeassistant.components.elmax # homeassistant.components.elmax
elmax_api==0.0.2 elmax_api==0.0.2

View File

@ -409,7 +409,7 @@ dynalite_devices==0.1.46
elgato==3.0.0 elgato==3.0.0
# homeassistant.components.elkm1 # homeassistant.components.elkm1
elkm1-lib==1.2.2 elkm1-lib==1.3.0
# homeassistant.components.elmax # homeassistant.components.elmax
elmax_api==0.0.2 elmax_api==0.0.2