Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ repos:
- --fix
- --unsafe-fixes
- id: ruff-format
- repo: https://github.com/asottile/pyupgrade
rev: v3.21.2
hooks:
- id: pyupgrade
args:
- --py314-plus
- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
hooks:
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/api_client.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Api client module."""

from __future__ import annotations

import asyncio
from dataclasses import dataclass
from typing import TYPE_CHECKING, Any
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/authentication.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Authentication module."""

from __future__ import annotations

import asyncio
from dataclasses import dataclass
from http import HTTPStatus
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/capabilities.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Device capabilities module."""

from __future__ import annotations

from abc import ABC
from dataclasses import dataclass, field, fields, is_dataclass
from enum import StrEnum
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/command.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Base command."""

from __future__ import annotations

from abc import ABC, abstractmethod
import asyncio
from dataclasses import dataclass, field
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Commands module."""

from __future__ import annotations

from enum import IntEnum, unique
from typing import TYPE_CHECKING

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Json commands module."""

from __future__ import annotations

from typing import TYPE_CHECKING

from . import auto_empty, station_action, station_state
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/advanced_mode.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Advanced mode command module."""

from __future__ import annotations

from deebot_client.events import AdvancedModeEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/auto_empty.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Auto empty commands."""

from __future__ import annotations

from typing import Any

from deebot_client.events.auto_empty import Frequency
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/battery.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Battery commands."""

from __future__ import annotations

from deebot_client.messages.json import OnBattery

from .common import JsonCommandWithMessageHandling
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/border_spin.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Border spin commands."""

from __future__ import annotations

from deebot_client.events import BorderSpinEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/border_switch.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Border switch commands."""

from __future__ import annotations

from deebot_client.events import BorderSwitchEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/carpet.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Carpet pressure command module."""

from __future__ import annotations

from deebot_client.events import CarpetAutoFanBoostEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/charge.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Charge commands."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.events import StateEvent
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/charge_state.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Charge state commands."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.events import StateEvent
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/child_lock.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Child lock commands."""

from __future__ import annotations

from deebot_client.events import ChildLockEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/clean.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Clean commands."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.events import StateEvent
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/clean_count.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Clean count command module."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/clean_logs.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""clean log commands."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.const import PATH_API_LG_LOG, REQUEST_HEADERS
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/clean_preference.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Clean preference command module."""

from __future__ import annotations

from deebot_client.events import CleanPreferenceEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/clear_map.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""ClearMap commands."""

from __future__ import annotations

from .common import ExecuteCommand


Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/common.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Base commands."""

from __future__ import annotations

from abc import ABC, abstractmethod
import time
from types import MappingProxyType
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/const.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
"""Command constants module."""

from __future__ import annotations

CODE = "code"
2 changes: 0 additions & 2 deletions deebot_client/commands/json/continuous_cleaning.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Continuous cleaning (break point) command module."""

from __future__ import annotations

from deebot_client.events import ContinuousCleaningEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/cross_map_border_warning.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Cross map border warning commands."""

from __future__ import annotations

from deebot_client.events import CrossMapBorderWarningEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/custom.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Custom command module."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.commands.json.common import JsonCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/cut_direction.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Cut direction command module."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/efficiency.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Efficiency mode command module."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/error.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Error commands."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.const import ERROR_CODES
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/fan_speed.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""(fan) speed commands."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/life_span.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Life span commands."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/map/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Maps commands."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/map/cached_map_info.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Cached map info commands."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.commands.json.common import JsonCommandWithMessageHandling
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/map/major_map.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Major map commands."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/mop_auto_wash_frequency.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Mop Auto-Wash Frequency command module."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/moveup_warning.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Move up lock commands."""

from __future__ import annotations

from deebot_client.events import MoveUpWarningEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/multimap_state.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Multimap state command module."""

from __future__ import annotations

from deebot_client.events import MultimapStateEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/network.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Network commands."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.command import CommandWithMessageHandling
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/ota.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Ota command module."""

from __future__ import annotations

from types import MappingProxyType
from typing import TYPE_CHECKING, Any

Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/play_sound.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Play sound commands."""

from __future__ import annotations

from .common import ExecuteCommand


Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/pos.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Position command module."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.events import Position, PositionsEvent
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/relocation.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Relocate commands."""

from __future__ import annotations

from .common import ExecuteCommand


Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/safe_protect.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Safe protect commands."""

from __future__ import annotations

from deebot_client.events import SafeProtectEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/station_action.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Charge commands."""

from __future__ import annotations

from typing import TYPE_CHECKING

from .common import ExecuteCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/station_state.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Battery commands."""

from __future__ import annotations

from deebot_client.messages.json.station_state import OnStationState

from .common import JsonCommandWithMessageHandling
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/stats.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Stats commands."""

from __future__ import annotations

from typing import TYPE_CHECKING, Any

from deebot_client.events import StatsEvent, TotalStatsEvent
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/sweep_mode.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""SweepMode command module for "Mop-Only" option."""

from __future__ import annotations

from deebot_client.events import SweepModeEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/true_detect.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""True detect command module."""

from __future__ import annotations

from deebot_client.events import TrueDetectEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
2 changes: 0 additions & 2 deletions deebot_client/commands/json/voice_assistant_state.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Voice assistant state command module."""

from __future__ import annotations

from deebot_client.events import VoiceAssistantStateEvent

from .common import GetEnableCommand, SetEnableCommand
Expand Down
Loading