Compare commits
8 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c693fefbf3 | ||
|
|
523ba949dd | ||
|
|
3c35d87fd2 | ||
|
|
6c2c531a19 | ||
|
|
f4e38ec521 | ||
|
|
ecb950da8a | ||
|
|
a7d4276671 | ||
|
|
ef0a3c3ddb |
21
.github/workflows/cron.yml
vendored
Normal file
21
.github/workflows/cron.yml
vendored
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
name: Validate with hassfest
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
pull_request:
|
||||||
|
schedule:
|
||||||
|
- cron: '0 0 * * *'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
validate:
|
||||||
|
runs-on: "ubuntu-latest"
|
||||||
|
steps:
|
||||||
|
- uses: "actions/checkout@v3"
|
||||||
|
|
||||||
|
- name: HACS validation
|
||||||
|
uses: "hacs/action@main"
|
||||||
|
with:
|
||||||
|
category: "integration"
|
||||||
|
|
||||||
|
- name: Hassfest validation
|
||||||
|
uses: "home-assistant/actions/hassfest@master"
|
||||||
@@ -102,7 +102,7 @@ async def async_setup_entry(
|
|||||||
) -> None:
|
) -> None:
|
||||||
"""Set up the owlet sensors from config entry."""
|
"""Set up the owlet sensors from config entry."""
|
||||||
|
|
||||||
coordinators: OwletCoordinator = hass.data[DOMAIN][config_entry.entry_id]
|
coordinators: OwletCoordinator = hass.data[DOMAIN][config_entry.entry_id].values()
|
||||||
|
|
||||||
async_add_entities(
|
async_add_entities(
|
||||||
OwletBinarySensor(coordinator, sensor)
|
OwletBinarySensor(coordinator, sensor)
|
||||||
@@ -122,7 +122,7 @@ class OwletBinarySensor(OwletBaseEntity, BinarySensorEntity):
|
|||||||
"""Initialize the binary sensor."""
|
"""Initialize the binary sensor."""
|
||||||
super().__init__(coordinator)
|
super().__init__(coordinator)
|
||||||
self.entity_description = sensor_description
|
self.entity_description = sensor_description
|
||||||
self._attr_unique_id = f"{self.sock.serial}-{self.entity_description.name}"
|
self._attr_unique_id = f"{self.sock.serial}-{self.entity_description.translation_key}"
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def is_on(self) -> bool:
|
def is_on(self) -> bool:
|
||||||
|
|||||||
@@ -5,6 +5,7 @@
|
|||||||
"config_flow": true,
|
"config_flow": true,
|
||||||
"documentation": "https://www.home-assistant.io/integrations/owlet",
|
"documentation": "https://www.home-assistant.io/integrations/owlet",
|
||||||
"iot_class": "cloud_polling",
|
"iot_class": "cloud_polling",
|
||||||
"requirements": ["pyowletapi==2023.5.30"],
|
"issue_tracker": "https://github.com/ryanbdclark/owlet/issues",
|
||||||
"version":"2023.5.7"
|
"requirements": ["pyowletapi==2023.07.01"],
|
||||||
|
"version":"2023.07.01"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -65,7 +65,7 @@
|
|||||||
"name": "Sock Diconnected Alert"
|
"name": "Sock Diconnected Alert"
|
||||||
},
|
},
|
||||||
"sock_off":{
|
"sock_off":{
|
||||||
"name":"sock_off"
|
"name":"Sock Off"
|
||||||
},
|
},
|
||||||
"awake":{
|
"awake":{
|
||||||
"name":"Awake"
|
"name":"Awake"
|
||||||
|
|||||||
@@ -65,7 +65,7 @@
|
|||||||
"name": "Sock Diconnected Alert"
|
"name": "Sock Diconnected Alert"
|
||||||
},
|
},
|
||||||
"sock_off":{
|
"sock_off":{
|
||||||
"name":"sock_off"
|
"name":"Sock Off"
|
||||||
},
|
},
|
||||||
"awake":{
|
"awake":{
|
||||||
"name":"Awake"
|
"name":"Awake"
|
||||||
|
|||||||
Reference in New Issue
Block a user