Skip to content

Commit

Permalink
Remove deprecated Fan{V2,SA1,ZA1,ZA3,ZA4}
Browse files Browse the repository at this point in the history
  • Loading branch information
rytilahti committed Jan 16, 2022
1 parent 53ddf57 commit d2bea27
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 68 deletions.
2 changes: 1 addition & 1 deletion miio/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
from miio.heater_miot import HeaterMiot
from miio.huizuo import Huizuo, HuizuoLampFan, HuizuoLampHeater, HuizuoLampScene
from miio.integrations.fan.dmaker import Fan1C, FanMiot, FanP5, FanP9, FanP10, FanP11
from miio.integrations.fan.zhimi import Fan, FanSA1, FanV2, FanZA1, FanZA4, FanZA5
from miio.integrations.fan.zhimi import Fan, FanZA5
from miio.integrations.petwaterdispenser import PetWaterDispenser
from miio.integrations.vacuum.dreame.dreamevacuum_miot import DreameVacuumMiot
from miio.integrations.vacuum.mijia import G1Vacuum
Expand Down
2 changes: 1 addition & 1 deletion miio/integrations/fan/zhimi/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# flake8: noqa
from .fan import Fan, FanSA1, FanV2, FanZA1, FanZA4
from .fan import Fan
from .zhimi_miot import FanZA5
66 changes: 0 additions & 66 deletions miio/integrations/fan/zhimi/fan.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
from miio import Device, DeviceStatus
from miio.click_common import EnumType, command, format_output
from miio.fan_common import FanException, LedBrightness, MoveDirection
from miio.utils import deprecated

_LOGGER = logging.getLogger(__name__)

Expand Down Expand Up @@ -371,68 +370,3 @@ def delay_off(self, seconds: int):
raise FanException("Invalid value for a delayed turn off: %s" % seconds)

return self.send("set_poweroff_time", [seconds])


@deprecated('use Fan(.., model="zhimi.fan.v2")')
class FanV2(Fan):
def __init__(
self,
ip: str = None,
token: str = None,
start_id: int = 0,
debug: int = 0,
lazy_discover: bool = True,
) -> None:
super().__init__(ip, token, start_id, debug, lazy_discover, model=MODEL_FAN_V2)


@deprecated('use Fan(.., model="zhimi.fan.sa1")')
class FanSA1(Fan):
def __init__(
self,
ip: str = None,
token: str = None,
start_id: int = 0,
debug: int = 0,
lazy_discover: bool = True,
) -> None:
super().__init__(ip, token, start_id, debug, lazy_discover, model=MODEL_FAN_SA1)


@deprecated('use Fan(.., model="zhimi.fan.za1")')
class FanZA1(Fan):
def __init__(
self,
ip: str = None,
token: str = None,
start_id: int = 0,
debug: int = 0,
lazy_discover: bool = True,
) -> None:
super().__init__(ip, token, start_id, debug, lazy_discover, model=MODEL_FAN_ZA1)


@deprecated('use Fan(.., model="zhimi.fan.za3")')
class FanZA3(Fan):
def __init__(
self,
ip: str = None,
token: str = None,
start_id: int = 0,
debug: int = 0,
lazy_discover: bool = True,
) -> None:
super().__init__(ip, token, start_id, debug, lazy_discover, model=MODEL_FAN_ZA3)


@deprecated('use Fan(.., model="zhimi.fan.za4")')
class FanZA4(Fan):
def __init__(
self,
ip: str = None,
token: str = None,
start_id: int = 0,
debug: int = 0,
lazy_discover: bool = True,
) -> None:
super().__init__(ip, token, start_id, debug, lazy_discover, model=MODEL_FAN_ZA4)

0 comments on commit d2bea27

Please sign in to comment.