Skip to content

Commit

Permalink
chore: skip ARG rules (midea-lan#144)
Browse files Browse the repository at this point in the history
Co-authored-by: Simone Chemelli <[email protected]>
  • Loading branch information
rokam and chemelli74 authored Jun 15, 2024
1 parent 9fc1c99 commit b95a7ec
Show file tree
Hide file tree
Showing 27 changed files with 34 additions and 34 deletions.
8 changes: 4 additions & 4 deletions midealocal/backports/enum.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ def __str__(self) -> str:

@staticmethod
def _generate_next_value_(
name: str,
start: int,
count: int,
last_values: list[Any],
name: str, # noqa: ARG004
start: int, # noqa: ARG004
count: int, # noqa: ARG004
last_values: list[Any], # noqa: ARG004
) -> Any:
"""Make `auto()` explicitly unsupported.
Expand Down
6 changes: 3 additions & 3 deletions midealocal/cloud.py
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ async def download_lua(
path: str,
device_type: int,
sn: str,
model_number: str | None,
model_number: str | None, # noqa: ARG002
manufacturer_code: str = "0000",
) -> str | None:
"""Download lua integration."""
Expand Down Expand Up @@ -541,7 +541,7 @@ async def login(self) -> bool:

async def list_appliances(
self,
home_id: str | None,
home_id: str | None, # noqa: ARG002
) -> dict[int, dict[str, Any]] | None:
"""List MSmart Cloud Devices."""
data = self._make_general_data()
Expand Down Expand Up @@ -731,7 +731,7 @@ async def login(self) -> bool:

async def list_appliances(
self,
home_id: str | None,
home_id: str | None, # noqa: ARG002
) -> dict[int, dict[str, Any]] | None:
"""List Midea Air devices."""
data = self._make_general_data()
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/a1/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea A1 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/b0/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize B0 Midea device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/b1/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea B1 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/b3/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea local B3 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/b4/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea B4 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/bf/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea BF device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/c3/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea C3 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/ca/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea CA device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/cc/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea CC device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/cf/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea CF device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/da/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea DA device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/db/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea DB device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/dc/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea DC device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/e1/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea E1 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/e6/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea E6 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/e8/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea E8 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/ea/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea EA device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/ec/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea EC device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/ed/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea ED device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/fb/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea FB device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/fd/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea FD device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/x26/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea x26 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/x34/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea x34 device."""
super().__init__(
Expand Down
2 changes: 1 addition & 1 deletion midealocal/devices/x40/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def __init__(
protocol: int,
model: str,
subtype: int,
customize: str,
customize: str, # noqa: ARG002
) -> None:
"""Initialize Midea x40 Device."""
super().__init__(
Expand Down
6 changes: 3 additions & 3 deletions midealocal/security.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def __init__(
self._fixed_key = format(fixed_key, "x").encode("ascii") if fixed_key else None
self._fixed_iv = format(fixed_iv, "x").encode("ascii") if fixed_iv else None

def sign(self, url: str, data: dict[str, Any] | str, random: str) -> str | None:
def sign(self, url: str, data: dict[str, Any] | str, random: str) -> str | None: # noqa: ARG002
"""Sign cloud data."""
msg: str = self._iot_key or ""
msg += str(data)
Expand Down Expand Up @@ -193,7 +193,7 @@ def __init__(self, login_key: str, iot_key: str, hmac_key: str) -> None:
"""Initialize Meiju Cloud security."""
super().__init__(login_key, iot_key, hmac_key, 10864842703515613082)

def encrypt_iam_password(self, login_id: str, data: str) -> str:
def encrypt_iam_password(self, login_id: str, data: str) -> str: # noqa: ARG002
"""Encrypt IAM password."""
md = md5()
md.update(data.encode("ascii"))
Expand Down Expand Up @@ -246,7 +246,7 @@ def __init__(self, login_key: str) -> None:
"""Initialize Midea Air Security."""
super().__init__(login_key, None, None)

def sign(self, url: str, data: dict[str, Any] | str, random: str) -> str:
def sign(self, url: str, data: dict[str, Any] | str, random: str) -> str: # noqa: ARG002
"""Sign Midea Air."""
if isinstance(data, str):
raise DataSignWrongType
Expand Down

0 comments on commit b95a7ec

Please sign in to comment.