Skip to content

Commit

Permalink
Pylint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
JeffLIrion committed Oct 28, 2024
1 parent c2ca4c4 commit a3a24bf
Show file tree
Hide file tree
Showing 12 changed files with 20 additions and 3 deletions.
1 change: 1 addition & 0 deletions androidtv/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
__version__ = "0.0.73"


# pylint: disable=too-many-positional-arguments
def setup(
host,
port=5555,
Expand Down
4 changes: 4 additions & 0 deletions androidtv/adb_manager/adb_manager_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ async def close(self):
"""Close the connection via the provided transport's ``close()`` method."""
await asyncio.get_running_loop().run_in_executor(None, self._adb.close)

# pylint: disable=too-many-positional-arguments
async def connect(
self,
rsa_keys=None,
Expand All @@ -56,6 +57,7 @@ async def connect(
None, self._adb.connect, rsa_keys, transport_timeout_s, auth_timeout_s, read_timeout_s, auth_callback
)

# pylint: disable=too-many-positional-arguments
async def pull(
self,
device_path,
Expand All @@ -69,6 +71,7 @@ async def pull(
None, self._adb.pull, device_path, local_path, progress_callback, transport_timeout_s, read_timeout_s
)

# pylint: disable=too-many-positional-arguments
async def push(
self,
local_path,
Expand All @@ -92,6 +95,7 @@ async def push(
read_timeout_s,
)

# pylint: disable=too-many-positional-arguments
async def shell(
self, command, transport_timeout_s=None, read_timeout_s=DEFAULT_READ_TIMEOUT_S, timeout_s=None, decode=True
):
Expand Down
3 changes: 2 additions & 1 deletion androidtv/androidtv/androidtv_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ class AndroidTVAsync(BaseTVAsync, BaseAndroidTV):
"""

# pylint: disable=too-many-positional-arguments, super-init-not-called
def __init__(
self,
host,
Expand All @@ -42,7 +43,7 @@ def __init__(
adb_server_port=5037,
state_detection_rules=None,
signer=None,
): # pylint: disable=super-init-not-called
):
BaseTVAsync.__init__(self, host, port, adbkey, adb_server_ip, adb_server_port, state_detection_rules, signer)

@classmethod
Expand Down
3 changes: 2 additions & 1 deletion androidtv/androidtv/androidtv_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ class AndroidTVSync(BaseTVSync, BaseAndroidTV):
"""

# pylint: disable=too-many-positional-arguments, super-init-not-called
def __init__(
self,
host,
Expand All @@ -42,7 +43,7 @@ def __init__(
adb_server_port=5037,
state_detection_rules=None,
signer=None,
): # pylint: disable=super-init-not-called
):
BaseTVSync.__init__(self, host, port, adbkey, adb_server_ip, adb_server_port, state_detection_rules, signer)

@classmethod
Expand Down
2 changes: 2 additions & 0 deletions androidtv/androidtv/base_androidtv.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ class BaseAndroidTV(BaseTV): # pylint: disable=too-few-public-methods
DEVICE_CLASS = "androidtv"
DEVICE_ENUM = constants.DeviceEnum.ANDROIDTV

# pylint: disable=too-many-positional-arguments
def __init__(self, host, port=5555, adbkey="", adb_server_ip="", adb_server_port=5037, state_detection_rules=None):
BaseTV.__init__(self, None, host, port, adbkey, adb_server_ip, adb_server_port, state_detection_rules)

Expand All @@ -42,6 +43,7 @@ def __init__(self, host, port=5555, adbkey="", adb_server_ip="", adb_server_port
# Home Assistant Update #
# #
# ======================================================================= #
# pylint: disable=too-many-positional-arguments
def _update(
self,
screen_on,
Expand Down
1 change: 1 addition & 0 deletions androidtv/basetv/basetv.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ class BaseTV(object): # pylint: disable=too-few-public-methods

DEVICE_ENUM = constants.DeviceEnum.BASETV

# pylint: disable=too-many-positional-arguments
def __init__(
self,
adb,
Expand Down
1 change: 1 addition & 0 deletions androidtv/basetv/basetv_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ class BaseTVAsync(BaseTV):
"""

# pylint: disable=too-many-positional-arguments
def __init__(
self,
host,
Expand Down
1 change: 1 addition & 0 deletions androidtv/basetv/basetv_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ class BaseTVSync(BaseTV):
"""

# pylint: disable=too-many-positional-arguments
def __init__(
self,
host,
Expand Down
2 changes: 2 additions & 0 deletions androidtv/firetv/base_firetv.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ class BaseFireTV(BaseTV): # pylint: disable=too-few-public-methods
DEVICE_CLASS = "firetv"
DEVICE_ENUM = constants.DeviceEnum.FIRETV

# pylint: disable=too-many-positional-arguments
def __init__(self, host, port=5555, adbkey="", adb_server_ip="", adb_server_port=5037, state_detection_rules=None):
BaseTV.__init__(self, None, host, port, adbkey, adb_server_ip, adb_server_port, state_detection_rules)

Expand All @@ -42,6 +43,7 @@ def __init__(self, host, port=5555, adbkey="", adb_server_ip="", adb_server_port
# Home Assistant Update #
# #
# ======================================================================= #
# pylint: disable=too-many-positional-arguments
def _update(self, screen_on, awake, wake_lock_size, current_app, media_session_state, running_apps, hdmi_input):
"""Get the info needed for a Home Assistant update.
Expand Down
1 change: 1 addition & 0 deletions androidtv/firetv/firetv_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ class FireTVAsync(BaseTVAsync, BaseFireTV):
"""

# pylint: disable=too-many-positional-arguments
def __init__(
self,
host,
Expand Down
3 changes: 2 additions & 1 deletion androidtv/firetv/firetv_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ class FireTVSync(BaseTVSync, BaseFireTV):
"""

# pylint: disable=too-many-positional-arguments, super-init-not-called
def __init__(
self,
host,
Expand All @@ -42,7 +43,7 @@ def __init__(
adb_server_port=5037,
state_detection_rules=None,
signer=None,
): # pylint: disable=super-init-not-called
):
BaseTVSync.__init__(self, host, port, adbkey, adb_server_ip, adb_server_port, state_detection_rules, signer)

@classmethod
Expand Down
1 change: 1 addition & 0 deletions androidtv/setup_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from .firetv.firetv_async import FireTVAsync


# pylint: disable=too-many-positional-arguments
async def setup(
host,
port=5555,
Expand Down

0 comments on commit a3a24bf

Please sign in to comment.