1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-12 00:02:21 +01:00

[config] Deprecate other *_SCHEMA constants (#8748)

This commit is contained in:
Jesse Hills
2025-05-13 07:43:38 +12:00
committed by GitHub
parent 71e88fe9b2
commit dcd786d21c
8 changed files with 52 additions and 15 deletions

View File

@@ -386,7 +386,7 @@ def validate_click_timing(value):
return value
BINARY_SENSOR_SCHEMA = (
_BINARY_SENSOR_SCHEMA = (
cv.ENTITY_BASE_SCHEMA.extend(web_server.WEBSERVER_SORTING_SCHEMA)
.extend(cv.MQTT_COMPONENT_SCHEMA)
.extend(
@@ -480,7 +480,12 @@ def binary_sensor_schema(
if default is not cv.UNDEFINED:
schema[cv.Optional(key, default=default)] = validator
return BINARY_SENSOR_SCHEMA.extend(schema)
return _BINARY_SENSOR_SCHEMA.extend(schema)
# Remove before 2025.11.0
BINARY_SENSOR_SCHEMA = binary_sensor_schema()
BINARY_SENSOR_SCHEMA.add_extra(cv.deprecated_schema_constant("binary_sensor"))
async def setup_binary_sensor_core_(var, config):