From f963997f35a6659216aab16bd99d259f4d950b71 Mon Sep 17 00:00:00 2001 From: onyx-and-iris Date: Sun, 1 Feb 2026 21:39:19 +0000 Subject: [PATCH] fixes bug with {EQ}.quality, it should use an invertic log scale. patch bump --- pyproject.toml | 61 +++++++++++++++++++++------------------------- xair_api/shared.py | 5 ++-- 2 files changed, 31 insertions(+), 35 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 375b91e..d52e135 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,20 +1,18 @@ [project] name = "xair-api" -version = "2.4.1" +version = "2.4.2" description = "Remote control Behringer X-Air | Midas MR mixers through OSC" -authors = [ - {name = "Onyx and Iris",email = "code@onyxandiris.online"} -] -license = {text = "MIT"} +authors = [{ name = "Onyx and Iris", email = "code@onyxandiris.online" }] +license = { text = "MIT" } readme = "README.md" requires-python = ">=3.10" dependencies = [ - "python-osc (>=1.9.3,<2.0.0)", - "tomli (>=2.0.1,<3.0) ; python_version < '3.11'" + "python-osc (>=1.9.3,<2.0.0)", + "tomli (>=2.0.1,<3.0) ; python_version < '3.11'", ] [tool.poetry.requires-plugins] -poethepoet = "^0.32.1" +poethepoet = "^0.35.0" [tool.poetry.group.dev.dependencies] pytest = "^8.3.4" @@ -62,27 +60,27 @@ legacy_tox_ini = """ [tool.ruff] exclude = [ - ".bzr", - ".direnv", - ".eggs", - ".git", - ".git-rewrite", - ".hg", - ".mypy_cache", - ".nox", - ".pants.d", - ".pytype", - ".ruff_cache", - ".svn", - ".tox", - ".venv", - "__pypackages__", - "_build", - "buck-out", - "build", - "dist", - "node_modules", - "venv", + ".bzr", + ".direnv", + ".eggs", + ".git", + ".git-rewrite", + ".hg", + ".mypy_cache", + ".nox", + ".pants.d", + ".pytype", + ".ruff_cache", + ".svn", + ".tox", + ".venv", + "__pypackages__", + "_build", + "buck-out", + "build", + "dist", + "node_modules", + "venv", ] # Same as Black. @@ -137,7 +135,4 @@ docstring-code-line-length = "dynamic" max-complexity = 10 [tool.ruff.lint.per-file-ignores] -"__init__.py" = [ - "E402", - "F401", -] +"__init__.py" = ["E402", "F401"] diff --git a/xair_api/shared.py b/xair_api/shared.py index e9083e0..7d7a53b 100644 --- a/xair_api/shared.py +++ b/xair_api/shared.py @@ -525,7 +525,8 @@ class EQ: @property def quality(self) -> float: - retval = util.log_get(0.3, 10, self.getter('q')[0]) + raw_value = self.getter('q')[0] + retval = util.log_get(0.3, 10, 1.0 - raw_value) return round(retval, 1) @quality.setter @@ -534,7 +535,7 @@ class EQ: self.logger.warning( f'quality got {val}, expected value in range 0.3 to 10.0' ) - self.setter('q', util.log_set(0.3, 10, val)) + self.setter('q', 1.0 - util.log_set(0.3, 10, val)) class GEQ: