From 8e982e8a6bc5db251c5ff088742b379a0f91aeee Mon Sep 17 00:00:00 2001 From: Danielle McLean Date: Sat, 22 Jun 2024 18:39:10 +1000 Subject: [PATCH] Fixups to placate Ruff linter --- pyproject.toml | 4 ++-- src/mpd_now_playable/cache.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 970ae21..e450218 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ mpd-now-playable = 'mpd_now_playable.cli:main' start = {call = 'mpd_now_playable.cli:main'} lint = 'ruff check src/mpd_now_playable' typecheck = 'mypy -p mpd_now_playable' -check = {composite = ['lint', 'typecheck']} +check = {composite = ['lint', 'typecheck'], keep_going = true} [tool.pdm.version] source = "scm" @@ -71,7 +71,7 @@ dev = [ [tool.mypy] mypy_path = 'stubs' -[tool.ruff] +[tool.ruff.lint] ignore-init-module-imports = true select = [ # pycodestyle diff --git a/src/mpd_now_playable/cache.py b/src/mpd_now_playable/cache.py index 8682058..0973a5f 100644 --- a/src/mpd_now_playable/cache.py +++ b/src/mpd_now_playable/cache.py @@ -19,10 +19,10 @@ with suppress(ImportError): class OrmsgpackSerializer(BaseSerializer): DEFAULT_ENCODING = None - def dumps(self, value: Any) -> bytes: + def dumps(self, value: object) -> bytes: return ormsgpack.packb(value) - def loads(self, value: Optional[bytes]) -> Any: + def loads(self, value: Optional[bytes]) -> object: if value is None: return None return ormsgpack.unpackb(value)