mirror of
https://github.com/basnijholt/adaptive-lighting.git
synced 2026-09-28 04:44:39 +02:00
Style with ruff and logging (#643)
* Formatting with ruff * more logging * Require on_only * Different implementation * More ruff * Remove new logging statements * Remove 'pylint: disable=protected' * style * fixes * ruff * Switch to ruff * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Fix .github * Fix * Add ignores * fix arg * fix B905 * Fix D * Fix more * Fix more * order * use path * moer path * Remove unused ignores * fix tes deps * fix typo --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
parent
97f388608a
commit
bb84684bce
12 changed files with 326 additions and 246 deletions
|
|
@ -1,13 +1,17 @@
|
|||
"""Extracts the dependencies of the components required for testing."""
|
||||
from collections import defaultdict
|
||||
from pathlib import Path
|
||||
|
||||
deps = defaultdict(list)
|
||||
components, packages = [], []
|
||||
|
||||
with open("core/requirements_test_all.txt") as f:
|
||||
requirements = Path("core") / "requirements_test_all.txt"
|
||||
|
||||
with requirements.open() as f:
|
||||
lines = f.readlines()
|
||||
|
||||
for line in lines:
|
||||
line = line.strip()
|
||||
line = line.strip() # noqa: PLW2901
|
||||
|
||||
if line.startswith("# homeassistant."):
|
||||
if components and packages:
|
||||
|
|
@ -34,4 +38,4 @@ required = [
|
|||
]
|
||||
to_install = [package for r in required for package in deps[r]]
|
||||
|
||||
print(" ".join(to_install))
|
||||
print(" ".join(to_install)) # noqa: T201
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue