Change name to entity_id Number platform error messages (#87961)

This commit is contained in:
G Johansson 2023-02-12 22:26:25 +01:00 committed by GitHub
parent 6ca4c5cfe7
commit 824a0475ae
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -94,7 +94,7 @@ async def async_set_value(entity: NumberEntity, service_call: ServiceCall) -> No
value = service_call.data["value"]
if value < entity.min_value or value > entity.max_value:
raise ValueError(
f"Value {value} for {entity.name} is outside valid range"
f"Value {value} for {entity.entity_id} is outside valid range"
f" {entity.min_value} - {entity.max_value}"
)
try: