Skip to content

Commit

Permalink
Remove the last references to dyson_cloud to fix "camera" log entry (#55
Browse files Browse the repository at this point in the history
)
  • Loading branch information
dotvezz authored Jul 14, 2023
1 parent 165cf6d commit 356c605
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 34 deletions.
13 changes: 8 additions & 5 deletions custom_components/dyson_local/camera.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
"""Camera platform for Dyson cloud."""
from typing import Callable
import logging
from datetime import timedelta

from homeassistant.core import HomeAssistant
from homeassistant.config_entries import ConfigEntry
from homeassistant.components.camera import Camera
from custom_components.dyson_local.vendor.libdyson.const import DEVICE_TYPE_360_EYE, DEVICE_TYPE_360_HEURIST
from custom_components.dyson_local.vendor.libdyson.cloud.cloud_360_eye import DysonCloud360Eye
from custom_components.dyson_local.vendor.libdyson.cloud import DysonDeviceInfo
from datetime import timedelta

from custom_components.dyson_local.cloud.const import DATA_ACCOUNT, DATA_DEVICES, DOMAIN
from .vendor.libdyson.const import DEVICE_TYPE_360_EYE, DEVICE_TYPE_360_HEURIST
from .vendor.libdyson.cloud.cloud_360_eye import DysonCloud360Eye
from .vendor.libdyson.cloud import DysonDeviceInfo

from .cloud.const import DATA_ACCOUNT, DATA_DEVICES
from .const import DOMAIN

_LOGGER = logging.getLogger(__name__)

Expand Down
4 changes: 2 additions & 2 deletions custom_components/dyson_local/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@
import logging
from typing import List, Optional

from .const import DATA_DEVICES, DOMAIN
from .utils import environmental_property
from .vendor.libdyson import DysonPureHotCoolLink

from custom_components.dyson_local.utils import environmental_property
from homeassistant.components.climate import ClimateEntity
from homeassistant.components.climate.const import (
CURRENT_HVAC_COOL,
Expand All @@ -25,7 +26,6 @@
from homeassistant.core import Callable, HomeAssistant

from . import DysonEntity
from .const import DATA_DEVICES, DOMAIN

_LOGGER = logging.getLogger(__name__)

Expand Down
24 changes: 0 additions & 24 deletions custom_components/dyson_local/cloud/__init__.py
Original file line number Diff line number Diff line change
@@ -1,24 +0,0 @@
"""Support for Dyson cloud account."""

import asyncio
import logging
from functools import partial

from homeassistant.exceptions import ConfigEntryNotReady
from ..vendor.libdyson.cloud.account import DysonAccountCN
from ..vendor.libdyson.cloud.device_info import DysonDeviceInfo
from ..vendor.libdyson.const import DEVICE_TYPE_360_EYE
from ..vendor.libdyson.discovery import DysonDiscovery
from ..vendor.libdyson.dyson_device import DysonDevice
from ..vendor.libdyson.exceptions import DysonException, DysonNetworkError
from homeassistant.config_entries import ConfigEntry, SOURCE_DISCOVERY
from homeassistant.const import CONF_HOST, EVENT_HOMEASSISTANT_STOP
from homeassistant.core import HomeAssistant, callback
from homeassistant.helpers.entity import Entity
from homeassistant.components.zeroconf import async_get_instance
from ..vendor.libdyson.cloud import DysonAccount
from custom_components.dyson_local import DOMAIN as DYSON_LOCAL_DOMAIN

from .const import CONF_AUTH, CONF_REGION, DATA_ACCOUNT, DATA_DEVICES, DOMAIN

_LOGGER = logging.getLogger(__name__)
2 changes: 0 additions & 2 deletions custom_components/dyson_local/cloud/const.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
DOMAIN = "dyson_cloud"

CONF_REGION = "region"
CONF_AUTH = "auth"

Expand Down
2 changes: 1 addition & 1 deletion custom_components/dyson_local/config_flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ async def async_step_host(self, info: Optional[dict] = None):
)

async def async_step_discovery(self, info: DysonDeviceInfo):
"""Handle step initialized by dyson_cloud discovery."""
"""Handle step initialized by MyDyson discovery."""
for entry in self._async_current_entries():
if entry.unique_id == info.serial:
return self.async_abort(reason="already_configured")
Expand Down

0 comments on commit 356c605

Please sign in to comment.