1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-26 14:08:21 +00:00

Enable more SIM ruff rules (#113015)

* SIM101 SIM103

* SIM107 SIM109

* SIM110

* SIM112 SIM113

* SIM115

* SIM116

* Fix

* Fix

* Fix
This commit is contained in:
Joost Lekkerkerker
2024-03-11 04:20:37 +01:00
committed by GitHub
parent e96ef4613c
commit cddce0ce0d
17 changed files with 41 additions and 70 deletions

View File

@@ -3050,10 +3050,7 @@ def _get_named_annotation(
def _has_valid_annotations(
annotations: list[nodes.NodeNG | None],
) -> bool:
for annotation in annotations:
if annotation is not None:
return True
return False
return any(annotation is not None for annotation in annotations)
def _get_module_platform(module_name: str) -> str | None: