mirror of
https://github.com/esphome/esphome.git
synced 2026-09-19 02:58:38 +00:00
[core] Fix CI: build_language_schema default, import budget, py312 ruff
This commit is contained in:
@@ -154,6 +154,10 @@ ignore = [
|
||||
"PLW1641", # Object does not implement `__hash__` method
|
||||
"PLR2004", # Magic value used in comparison, consider replacing {value} with a constant variable
|
||||
"PLW2901", # Outer {outer_kind} variable {name} overwritten by inner {inner_kind} target
|
||||
# PEP 695 type-parameter syntax, newly flagged by the 3.12 target. Adopting it
|
||||
# repo-wide is out of scope for the validation-engine swap; revisit separately.
|
||||
"UP046", # Generic class uses `Generic` subclass instead of type parameters
|
||||
"UP047", # Generic function should use type parameters
|
||||
]
|
||||
|
||||
[tool.ruff.lint.isort]
|
||||
|
||||
@@ -1162,9 +1162,11 @@ def convert_keys(converted, schema, path):
|
||||
"value": str(default_value),
|
||||
"components": components,
|
||||
}
|
||||
elif hasattr(k, "default") and str(k.default) != "...":
|
||||
elif hasattr(k, "default") and not isinstance(k.default, probatio.Undefined):
|
||||
default_value = k.default()
|
||||
if default_value is not None:
|
||||
if default_value is not None and not isinstance(
|
||||
default_value, probatio.Undefined
|
||||
):
|
||||
result["default"] = str(default_value)
|
||||
|
||||
# UI hint from ``cv.Optional`` / ``cv.Required`` — surfaced
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"target_module": "esphome.__main__",
|
||||
"margin_pct": 15,
|
||||
"cumulative_us": 91000
|
||||
"cumulative_us": 127000
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user