Compare commits

..

No commits in common. '691b5c24759c70654caa95a5cb1e62231b406d2e' and '6257b65687b69177b1b8ec26ee9b2744ec21e18b' have entirely different histories.

@ -25,6 +25,7 @@ import homeassistant.helpers.config_validation as cv
import homeassistant.helpers.event as ha_event import homeassistant.helpers.event as ha_event
from homeassistant.setup import async_when_setup from homeassistant.setup import async_when_setup
from homeassistant.helpers.typing import HomeAssistantType
from homeassistant.helpers.update_coordinator import ( from homeassistant.helpers.update_coordinator import (
CoordinatorEntity, CoordinatorEntity,
DataUpdateCoordinator, DataUpdateCoordinator,
@ -92,7 +93,16 @@ async def async_setup_entry(hass, entry):
# We add trackers to the context # We add trackers to the context
await context.init_context(hass) await context.init_context(hass)
await hass.config_entries.async_forward_entry_setups(entry, ["device_tracker", "switch", "sensor", "binary_sensor", "siren"]) hass.async_create_task(
hass.config_entries.async_forward_entry_setup(entry, "device_tracker"))
hass.async_create_task(
hass.config_entries.async_forward_entry_setup(entry, "switch"))
hass.async_create_task(
hass.config_entries.async_forward_entry_setup(entry, "sensor"))
hass.async_create_task(
hass.config_entries.async_forward_entry_setup(entry, "binary_sensor"))
hass.async_create_task(
hass.config_entries.async_forward_entry_setup(entry, "siren"))
return True return True

@ -3,7 +3,7 @@
import logging import logging
from typing import Any, Mapping from typing import Any, Mapping
from homeassistant.components.device_tracker.const import DOMAIN, SourceType from homeassistant.components.device_tracker.const import DOMAIN, SOURCE_TYPE_GPS
from homeassistant.components.device_tracker.config_entry import TrackerEntity from homeassistant.components.device_tracker.config_entry import TrackerEntity
from homeassistant.helpers.update_coordinator import ( from homeassistant.helpers.update_coordinator import (
@ -78,7 +78,7 @@ class GeoRideTrackerEntity(CoordinatorEntity, TrackerEntity):
@property @property
def source_type(self): def source_type(self):
"""Return the source type, eg gps or router, of the device.""" """Return the source type, eg gps or router, of the device."""
return SourceType.GPS return SOURCE_TYPE_GPS
@property @property
def location_accuracy(self): def location_accuracy(self):

@ -11,5 +11,5 @@
], ],
"dependencies": [], "dependencies": [],
"codeowners": ["ptimatth"], "codeowners": ["ptimatth"],
"version": "1.1.1" "version": "1.1.0"
} }

@ -4,5 +4,5 @@
"render_readme": true, "render_readme": true,
"domains": ["devices_tracker", "sensor"], "domains": ["devices_tracker", "sensor"],
"country": ["FR"], "country": ["FR"],
"homeassistant": "2024.11.0" "homeassistant": "2023.2.0"
} }
Loading…
Cancel
Save