mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 03:07:37 +00:00
commit
d1219d0b41
@ -1,13 +1,15 @@
|
|||||||
{
|
{
|
||||||
"config": {
|
"config": {
|
||||||
"abort": {
|
"abort": {
|
||||||
"existing_instance_updated": "La configuration existante a \u00e9t\u00e9 mise \u00e0 jour."
|
"existing_instance_updated": "La configuration existante a \u00e9t\u00e9 mise \u00e0 jour.",
|
||||||
|
"single_instance_allowed": "Une seule configuration d'AdGuard Home est autoris\u00e9e."
|
||||||
},
|
},
|
||||||
"error": {
|
"error": {
|
||||||
"connection_error": "\u00c9chec de connexion."
|
"connection_error": "\u00c9chec de connexion."
|
||||||
},
|
},
|
||||||
"step": {
|
"step": {
|
||||||
"hassio_confirm": {
|
"hassio_confirm": {
|
||||||
|
"description": "Voulez-vous configurer Home Assistant pour qu'il se connecte \u00e0 AdGuard Home fourni par le module compl\u00e9mentaire Hass.io: {addon} ?",
|
||||||
"title": "AdGuard Home via le module compl\u00e9mentaire Hass.io"
|
"title": "AdGuard Home via le module compl\u00e9mentaire Hass.io"
|
||||||
},
|
},
|
||||||
"user": {
|
"user": {
|
||||||
@ -16,8 +18,11 @@
|
|||||||
"password": "Mot de passe",
|
"password": "Mot de passe",
|
||||||
"port": "Port",
|
"port": "Port",
|
||||||
"ssl": "AdGuard Home utilise un certificat SSL",
|
"ssl": "AdGuard Home utilise un certificat SSL",
|
||||||
"username": "Nom d'utilisateur"
|
"username": "Nom d'utilisateur",
|
||||||
}
|
"verify_ssl": "AdGuard Home utilise un certificat appropri\u00e9"
|
||||||
|
},
|
||||||
|
"description": "Configurez votre instance AdGuard Home pour permettre la surveillance et le contr\u00f4le.",
|
||||||
|
"title": "Liez votre AdGuard Home."
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"title": "AdGuard Home"
|
"title": "AdGuard Home"
|
||||||
|
@ -8,6 +8,7 @@
|
|||||||
},
|
},
|
||||||
"error": {
|
"error": {
|
||||||
"already_configured": "L'appareil est d\u00e9j\u00e0 configur\u00e9",
|
"already_configured": "L'appareil est d\u00e9j\u00e0 configur\u00e9",
|
||||||
|
"already_in_progress": "Le flux de configuration de l'appareil est d\u00e9j\u00e0 en cours.",
|
||||||
"device_unavailable": "L'appareil n'est pas disponible",
|
"device_unavailable": "L'appareil n'est pas disponible",
|
||||||
"faulty_credentials": "Mauvaises informations d'identification de l'utilisateur"
|
"faulty_credentials": "Mauvaises informations d'identification de l'utilisateur"
|
||||||
},
|
},
|
||||||
|
@ -108,11 +108,11 @@ SENSOR_TYPES = {
|
|||||||
"rainchance_3d": ["Rainchance 3d", "%", "mdi:weather-pouring"],
|
"rainchance_3d": ["Rainchance 3d", "%", "mdi:weather-pouring"],
|
||||||
"rainchance_4d": ["Rainchance 4d", "%", "mdi:weather-pouring"],
|
"rainchance_4d": ["Rainchance 4d", "%", "mdi:weather-pouring"],
|
||||||
"rainchance_5d": ["Rainchance 5d", "%", "mdi:weather-pouring"],
|
"rainchance_5d": ["Rainchance 5d", "%", "mdi:weather-pouring"],
|
||||||
"sunchance_1d": ["Sunchance 1d", "%", "mdi:weather-partlycloudy"],
|
"sunchance_1d": ["Sunchance 1d", "%", "mdi:weather-partly-cloudy"],
|
||||||
"sunchance_2d": ["Sunchance 2d", "%", "mdi:weather-partlycloudy"],
|
"sunchance_2d": ["Sunchance 2d", "%", "mdi:weather-partly-cloudy"],
|
||||||
"sunchance_3d": ["Sunchance 3d", "%", "mdi:weather-partlycloudy"],
|
"sunchance_3d": ["Sunchance 3d", "%", "mdi:weather-partly-cloudy"],
|
||||||
"sunchance_4d": ["Sunchance 4d", "%", "mdi:weather-partlycloudy"],
|
"sunchance_4d": ["Sunchance 4d", "%", "mdi:weather-partly-cloudy"],
|
||||||
"sunchance_5d": ["Sunchance 5d", "%", "mdi:weather-partlycloudy"],
|
"sunchance_5d": ["Sunchance 5d", "%", "mdi:weather-partly-cloudy"],
|
||||||
"windforce_1d": ["Wind force 1d", "Bft", "mdi:weather-windy"],
|
"windforce_1d": ["Wind force 1d", "Bft", "mdi:weather-windy"],
|
||||||
"windforce_2d": ["Wind force 2d", "Bft", "mdi:weather-windy"],
|
"windforce_2d": ["Wind force 2d", "Bft", "mdi:weather-windy"],
|
||||||
"windforce_3d": ["Wind force 3d", "Bft", "mdi:weather-windy"],
|
"windforce_3d": ["Wind force 3d", "Bft", "mdi:weather-windy"],
|
||||||
|
@ -193,7 +193,7 @@ SENSOR_TYPES = {
|
|||||||
"%",
|
"%",
|
||||||
"%",
|
"%",
|
||||||
"%",
|
"%",
|
||||||
"mdi:weather-partlycloudy",
|
"mdi:weather-partly-cloudy",
|
||||||
["currently", "hourly", "daily"],
|
["currently", "hourly", "daily"],
|
||||||
],
|
],
|
||||||
"humidity": [
|
"humidity": [
|
||||||
@ -380,11 +380,11 @@ CONDITION_PICTURES = {
|
|||||||
"cloudy": ["/static/images/darksky/weather-cloudy.svg", "mdi:weather-cloudy"],
|
"cloudy": ["/static/images/darksky/weather-cloudy.svg", "mdi:weather-cloudy"],
|
||||||
"partly-cloudy-day": [
|
"partly-cloudy-day": [
|
||||||
"/static/images/darksky/weather-partlycloudy.svg",
|
"/static/images/darksky/weather-partlycloudy.svg",
|
||||||
"mdi:weather-partlycloudy",
|
"mdi:weather-partly-cloudy",
|
||||||
],
|
],
|
||||||
"partly-cloudy-night": [
|
"partly-cloudy-night": [
|
||||||
"/static/images/darksky/weather-cloudy.svg",
|
"/static/images/darksky/weather-cloudy.svg",
|
||||||
"mdi:weather-partlycloudy",
|
"mdi:weather-partly-cloudy",
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -40,5 +40,16 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"title": "deCONZ Zigbee gateway"
|
"title": "deCONZ Zigbee gateway"
|
||||||
|
},
|
||||||
|
"options": {
|
||||||
|
"step": {
|
||||||
|
"async_step_deconz_devices": {
|
||||||
|
"data": {
|
||||||
|
"allow_clip_sensor": "Allow deCONZ CLIP sensors",
|
||||||
|
"allow_deconz_groups": "Allow deCONZ light groups"
|
||||||
|
},
|
||||||
|
"description": "Configure visibility of deCONZ device types"
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -2,7 +2,9 @@
|
|||||||
"config": {
|
"config": {
|
||||||
"abort": {
|
"abort": {
|
||||||
"already_configured": "Ce pont est d\u00e9j\u00e0 configur\u00e9",
|
"already_configured": "Ce pont est d\u00e9j\u00e0 configur\u00e9",
|
||||||
|
"already_in_progress": "Le flux de configuration pour le pont est d\u00e9j\u00e0 en cours.",
|
||||||
"no_bridges": "Aucun pont deCONZ n'a \u00e9t\u00e9 d\u00e9couvert",
|
"no_bridges": "Aucun pont deCONZ n'a \u00e9t\u00e9 d\u00e9couvert",
|
||||||
|
"not_deconz_bridge": "Pas un pont deCONZ",
|
||||||
"one_instance_only": "Le composant prend uniquement en charge une instance deCONZ",
|
"one_instance_only": "Le composant prend uniquement en charge une instance deCONZ",
|
||||||
"updated_instance": "Instance deCONZ mise \u00e0 jour avec la nouvelle adresse d'h\u00f4te"
|
"updated_instance": "Instance deCONZ mise \u00e0 jour avec la nouvelle adresse d'h\u00f4te"
|
||||||
},
|
},
|
||||||
|
@ -76,8 +76,16 @@ class HomematicipGenericDevice(Entity):
|
|||||||
|
|
||||||
def _async_device_changed(self, *args, **kwargs):
|
def _async_device_changed(self, *args, **kwargs):
|
||||||
"""Handle device state changes."""
|
"""Handle device state changes."""
|
||||||
_LOGGER.debug("Event %s (%s)", self.name, self._device.modelType)
|
# Don't update disabled entities
|
||||||
self.async_schedule_update_ha_state()
|
if self.enabled:
|
||||||
|
_LOGGER.debug("Event %s (%s)", self.name, self._device.modelType)
|
||||||
|
self.async_schedule_update_ha_state()
|
||||||
|
else:
|
||||||
|
_LOGGER.debug(
|
||||||
|
"Device Changed Event for %s (%s) not fired. Entity is disabled.",
|
||||||
|
self.name,
|
||||||
|
self._device.modelType,
|
||||||
|
)
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def name(self) -> str:
|
def name(self) -> str:
|
||||||
|
@ -10,6 +10,7 @@
|
|||||||
"error": {
|
"error": {
|
||||||
"invalid_credentials": "Invalid credentials",
|
"invalid_credentials": "Invalid credentials",
|
||||||
"invalid_username": "Invalid username",
|
"invalid_username": "Invalid username",
|
||||||
|
"unexpected": "Unexpected error communicating with Life360 server",
|
||||||
"user_already_configured": "Account has already been configured"
|
"user_already_configured": "Account has already been configured"
|
||||||
},
|
},
|
||||||
"step": {
|
"step": {
|
||||||
|
@ -14,7 +14,7 @@ SENSORS = {
|
|||||||
"V_DIMMER": ["%", "mdi:percent"],
|
"V_DIMMER": ["%", "mdi:percent"],
|
||||||
"V_PERCENTAGE": ["%", "mdi:percent"],
|
"V_PERCENTAGE": ["%", "mdi:percent"],
|
||||||
"V_PRESSURE": [None, "mdi:gauge"],
|
"V_PRESSURE": [None, "mdi:gauge"],
|
||||||
"V_FORECAST": [None, "mdi:weather-partlycloudy"],
|
"V_FORECAST": [None, "mdi:weather-partly-cloudy"],
|
||||||
"V_RAIN": [None, "mdi:weather-rainy"],
|
"V_RAIN": [None, "mdi:weather-rainy"],
|
||||||
"V_RAINRATE": [None, "mdi:weather-rainy"],
|
"V_RAINRATE": [None, "mdi:weather-rainy"],
|
||||||
"V_WIND": [None, "mdi:weather-windy"],
|
"V_WIND": [None, "mdi:weather-windy"],
|
||||||
|
@ -1,7 +1,18 @@
|
|||||||
{
|
{
|
||||||
"config": {
|
"config": {
|
||||||
"abort": {
|
"abort": {
|
||||||
|
"not_internet_accessible": "Votre instance de Home Assistant doit \u00eatre accessible depuis Internet pour recevoir les messages de Plaato Airlock.",
|
||||||
"one_instance_allowed": "Une seule instance est n\u00e9cessaire."
|
"one_instance_allowed": "Une seule instance est n\u00e9cessaire."
|
||||||
}
|
},
|
||||||
|
"create_entry": {
|
||||||
|
"default": "Pour envoyer des \u00e9v\u00e9nements \u00e0 Home Assistant, vous devez configurer la fonction Webhook dans Plaato Airlock. \n\n Remplissez les informations suivantes: \n\n - URL: ` {webhook_url} ` \n - M\u00e9thode: POST \n\n Voir [la documentation] ( {docs_url} ) pour plus de d\u00e9tails."
|
||||||
|
},
|
||||||
|
"step": {
|
||||||
|
"user": {
|
||||||
|
"description": "\u00cates-vous s\u00fbr de vouloir installer le Plaato Airlock ?",
|
||||||
|
"title": "Configurer le Webhook Plaato"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"title": "Plaato Airlock"
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -41,7 +41,7 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend(
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
|
def setup_platform(hass, config, add_entities, discovery_info=None):
|
||||||
"""Set up the qBittorrent sensors."""
|
"""Set up the qBittorrent sensors."""
|
||||||
from qbittorrent.client import Client, LoginRequired
|
from qbittorrent.client import Client, LoginRequired
|
||||||
|
|
||||||
@ -62,7 +62,7 @@ async def async_setup_platform(hass, config, async_add_entities, discovery_info=
|
|||||||
sensor = QBittorrentSensor(sensor_type, client, name, LoginRequired)
|
sensor = QBittorrentSensor(sensor_type, client, name, LoginRequired)
|
||||||
dev.append(sensor)
|
dev.append(sensor)
|
||||||
|
|
||||||
async_add_entities(dev, True)
|
add_entities(dev, True)
|
||||||
|
|
||||||
|
|
||||||
def format_speed(speed):
|
def format_speed(speed):
|
||||||
@ -105,7 +105,7 @@ class QBittorrentSensor(Entity):
|
|||||||
"""Return the unit of measurement of this entity, if any."""
|
"""Return the unit of measurement of this entity, if any."""
|
||||||
return self._unit_of_measurement
|
return self._unit_of_measurement
|
||||||
|
|
||||||
async def async_update(self):
|
def update(self):
|
||||||
"""Get the latest data from qBittorrent and updates the state."""
|
"""Get the latest data from qBittorrent and updates the state."""
|
||||||
try:
|
try:
|
||||||
data = self.client.sync()
|
data = self.client.sync()
|
||||||
@ -113,7 +113,6 @@ class QBittorrentSensor(Entity):
|
|||||||
except RequestException:
|
except RequestException:
|
||||||
_LOGGER.error("Connection lost")
|
_LOGGER.error("Connection lost")
|
||||||
self._available = False
|
self._available = False
|
||||||
return
|
|
||||||
except self._exception:
|
except self._exception:
|
||||||
_LOGGER.error("Invalid authentication")
|
_LOGGER.error("Invalid authentication")
|
||||||
return
|
return
|
||||||
|
@ -26,11 +26,12 @@ class TuyaSwitch(TuyaDevice, SwitchDevice):
|
|||||||
"""Init Tuya switch device."""
|
"""Init Tuya switch device."""
|
||||||
super().__init__(tuya)
|
super().__init__(tuya)
|
||||||
self.entity_id = ENTITY_ID_FORMAT.format(tuya.object_id())
|
self.entity_id = ENTITY_ID_FORMAT.format(tuya.object_id())
|
||||||
|
self._is_on = False
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def is_on(self):
|
def is_on(self):
|
||||||
"""Return true if switch is on."""
|
"""Return true if switch is on."""
|
||||||
return self.tuya.state()
|
return self._is_on
|
||||||
|
|
||||||
def turn_on(self, **kwargs):
|
def turn_on(self, **kwargs):
|
||||||
"""Turn the switch on."""
|
"""Turn the switch on."""
|
||||||
@ -39,3 +40,7 @@ class TuyaSwitch(TuyaDevice, SwitchDevice):
|
|||||||
def turn_off(self, **kwargs):
|
def turn_off(self, **kwargs):
|
||||||
"""Turn the device off."""
|
"""Turn the device off."""
|
||||||
self.tuya.turn_off()
|
self.tuya.turn_off()
|
||||||
|
|
||||||
|
def update(self):
|
||||||
|
"""Update switch device."""
|
||||||
|
self._is_on = self.tuya.state()
|
||||||
|
@ -22,5 +22,17 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"title": "UniFi Controller"
|
"title": "UniFi Controller"
|
||||||
|
},
|
||||||
|
"options": {
|
||||||
|
"step": {
|
||||||
|
"device_tracker": {
|
||||||
|
"data": {
|
||||||
|
"detection_time": "Time in seconds from last seen until considered away",
|
||||||
|
"track_clients": "Track network clients",
|
||||||
|
"track_devices": "Track network devices (Ubiquiti devices)",
|
||||||
|
"track_wired_clients": "Include wired network clients"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -150,7 +150,9 @@ def update_items(controller, async_add_entities, tracked):
|
|||||||
|
|
||||||
for client_id in controller.api.clients:
|
for client_id in controller.api.clients:
|
||||||
|
|
||||||
if client_id in tracked and tracked[client_id].entity_id:
|
if client_id in tracked:
|
||||||
|
if not tracked[client_id].enabled:
|
||||||
|
continue
|
||||||
LOGGER.debug(
|
LOGGER.debug(
|
||||||
"Updating UniFi tracked client %s (%s)",
|
"Updating UniFi tracked client %s (%s)",
|
||||||
tracked[client_id].entity_id,
|
tracked[client_id].entity_id,
|
||||||
@ -183,7 +185,9 @@ def update_items(controller, async_add_entities, tracked):
|
|||||||
|
|
||||||
for device_id in controller.api.devices:
|
for device_id in controller.api.devices:
|
||||||
|
|
||||||
if device_id in tracked and tracked[device_id].entity_id:
|
if device_id in tracked:
|
||||||
|
if not tracked[device_id].enabled:
|
||||||
|
continue
|
||||||
LOGGER.debug(
|
LOGGER.debug(
|
||||||
"Updating UniFi tracked device %s (%s)",
|
"Updating UniFi tracked device %s (%s)",
|
||||||
tracked[device_id].entity_id,
|
tracked[device_id].entity_id,
|
||||||
|
@ -1,7 +1,12 @@
|
|||||||
{
|
{
|
||||||
"config": {
|
"config": {
|
||||||
|
"abort": {
|
||||||
|
"no_devices_found": "Aucun p\u00e9riph\u00e9rique Wemo trouv\u00e9 sur le r\u00e9seau.",
|
||||||
|
"single_instance_allowed": "Une seule configuration de Wemo est possible."
|
||||||
|
},
|
||||||
"step": {
|
"step": {
|
||||||
"confirm": {
|
"confirm": {
|
||||||
|
"description": "Voulez-vous configurer Wemo?",
|
||||||
"title": "Wemo"
|
"title": "Wemo"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -304,6 +304,8 @@ class ZHAGateway:
|
|||||||
manufacturer=zha_device.manufacturer,
|
manufacturer=zha_device.manufacturer,
|
||||||
model=zha_device.model,
|
model=zha_device.model,
|
||||||
)
|
)
|
||||||
|
entry = self.zha_storage.async_get_or_create(zha_device)
|
||||||
|
zha_device.async_update_last_seen(entry.last_seen)
|
||||||
return zha_device
|
return zha_device
|
||||||
|
|
||||||
@callback
|
@callback
|
||||||
@ -356,10 +358,6 @@ class ZHAGateway:
|
|||||||
)
|
)
|
||||||
await self._async_device_joined(device, zha_device)
|
await self._async_device_joined(device, zha_device)
|
||||||
|
|
||||||
# This is real traffic from a device so lets update last seen on the entry
|
|
||||||
entry = self.zha_storage.async_get_or_create(zha_device)
|
|
||||||
zha_device.async_update_last_seen(entry.last_seen)
|
|
||||||
|
|
||||||
device_info = async_get_device_info(
|
device_info = async_get_device_info(
|
||||||
self._hass, zha_device, self.ha_device_registry
|
self._hass, zha_device, self.ha_device_registry
|
||||||
)
|
)
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
"""Constants used by Home Assistant components."""
|
"""Constants used by Home Assistant components."""
|
||||||
MAJOR_VERSION = 0
|
MAJOR_VERSION = 0
|
||||||
MINOR_VERSION = 98
|
MINOR_VERSION = 98
|
||||||
PATCH_VERSION = "0"
|
PATCH_VERSION = "1"
|
||||||
__short_version__ = "{}.{}".format(MAJOR_VERSION, MINOR_VERSION)
|
__short_version__ = "{}.{}".format(MAJOR_VERSION, MINOR_VERSION)
|
||||||
__version__ = "{}.{}".format(__short_version__, PATCH_VERSION)
|
__version__ = "{}.{}".format(__short_version__, PATCH_VERSION)
|
||||||
REQUIRED_PYTHON_VER = (3, 6, 0)
|
REQUIRED_PYTHON_VER = (3, 6, 0)
|
||||||
|
@ -229,6 +229,11 @@ class Entity:
|
|||||||
# are used to perform a very specific function. Overwriting these may
|
# are used to perform a very specific function. Overwriting these may
|
||||||
# produce undesirable effects in the entity's operation.
|
# produce undesirable effects in the entity's operation.
|
||||||
|
|
||||||
|
@property
|
||||||
|
def enabled(self):
|
||||||
|
"""Return if the entity is enabled in the entity registry."""
|
||||||
|
return self.registry_entry is None or not self.registry_entry.disabled
|
||||||
|
|
||||||
@callback
|
@callback
|
||||||
def async_set_context(self, context):
|
def async_set_context(self, context):
|
||||||
"""Set the context the entity currently operates under."""
|
"""Set the context the entity currently operates under."""
|
||||||
|
@ -552,8 +552,10 @@ async def test_disabled_in_entity_registry(hass):
|
|||||||
await hass.async_block_till_done()
|
await hass.async_block_till_done()
|
||||||
assert entry2 != entry
|
assert entry2 != entry
|
||||||
assert ent.registry_entry == entry2
|
assert ent.registry_entry == entry2
|
||||||
|
assert ent.enabled is True
|
||||||
|
|
||||||
entry3 = registry.async_update_entity("hello.world", disabled_by="user")
|
entry3 = registry.async_update_entity("hello.world", disabled_by="user")
|
||||||
await hass.async_block_till_done()
|
await hass.async_block_till_done()
|
||||||
assert entry3 != entry2
|
assert entry3 != entry2
|
||||||
assert ent.registry_entry == entry3
|
assert ent.registry_entry == entry3
|
||||||
|
assert ent.enabled is False
|
||||||
|
Loading…
x
Reference in New Issue
Block a user