Bump ruff from 0.3.7 to 0.4.3 (#1273)
authordependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Tue, 7 May 2024 13:33:01 +0000 (15:33 +0200)
committerGitHub <noreply@github.com>
Tue, 7 May 2024 13:33:01 +0000 (15:33 +0200)
* Bump ruff from 0.3.7 to 0.4.3

Bumps [ruff](https://github.com/astral-sh/ruff) from 0.3.7 to 0.4.3.
- [Release notes](https://github.com/astral-sh/ruff/releases)
- [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md)
- [Commits](https://github.com/astral-sh/ruff/compare/v0.3.7...v0.4.3)

---
updated-dependencies:
- dependency-name: ruff
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
* lint

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Marcel van der Veldt <m.vanderveldt@outlook.com>
music_assistant/server/helpers/api.py
pyproject.toml

index c0bf9345e076b6865c2c9b71c1a1257bd6f70ae7..0b24b5ccfe1de237395edde015ad3184247dc57c 100644 (file)
@@ -62,7 +62,7 @@ def parse_arguments(
     if strict:
         for key, value in args.items():
             if key not in func_sig.parameters:
-                raise KeyError("Invalid parameter: '%s'" % key)
+                raise KeyError(f"Invalid parameter: '{key}'")
     # parse arguments to correct type
     for name, param in func_sig.parameters.items():
         value = args.get(name)
@@ -125,7 +125,7 @@ def parse_value(name: str, value: Any, value_type: Any, default: Any = MISSING)
             # raise exception, we have no idea how to handle this value
             raise TypeError(err)
         # failed to parse the (sub) value but None allowed, log only
-        logging.getLogger(__name__).warn(err)
+        logging.getLogger(__name__).warning(err)
         return None
     if origin is type:
         return eval(value)  # pylint: disable=eval-used
index e34d2e16578cda1d98ad0959498bd006ea621140..45f5c8292f93a7d698ab0188379a465488fb59aa 100644 (file)
@@ -53,7 +53,7 @@ test = [
   "pytest==8.2.0",
   "pytest-aiohttp==1.0.5",
   "pytest-cov==5.0.0",
-  "ruff==0.3.7",
+  "ruff==0.4.3",
 ]
 
 [project.scripts]