hass-virtual icon indicating copy to clipboard operation
hass-virtual copied to clipboard

Virtual Lock not available after upgrade

Open jbell968 opened this issue 4 years ago • 5 comments

I just upgraded Homme Assistant and the virtual lock now shows as unavailable. I tried commenting out the lock in configuration.yaml, restarting, manually deleting the entity, and re-adding to no avail. System info below:

System Health

version core-2021.11.0b5
installation_type Home Assistant OS
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.9.7
os_name Linux
os_version 5.10.17-v8
arch aarch64
timezone America/New_York
host_os Home Assistant OS 6.6
update_channel beta
supervisor_version supervisor-2021.10.8
docker_version 20.10.8
disk_total 28.6 GB
disk_used 24.0 GB
healthy true
supported true
board rpi4-64
supervisor_api ok
version_api ok
installed_addons Samba share (9.5.1), CEC Scanner (3.0), Samba Backup (5.0.0), Terminal & SSH (9.2.1), Duck DNS (1.14.0), Dnsmasq (1.4.4), WireGuard (0.5.1), Visual Studio Code (3.6.2), Mosquitto broker (6.0.1), ESPHome (2021.10.3), room-assistant (2.19.0), File editor (5.3.3)

jbell968 avatar Nov 03 '21 14:11 jbell968

Hi @jbell968, could you try to add lock and call:

service: virtual.set_available
data:
  entity_id: __name_of_entity__
  value: true

Tony763 avatar Nov 03 '21 14:11 Tony763

Hello,

I have the same problem. The lock is unavailabe at startup. Calling virtual.set_available service as described above works and the lock becomes available. But if I set the config option "initial_availability: true", my config doesn't pass the check config test with the following error: "Invalid config for [lock.virtual]: [initial_availability] is an invalid option for [lock.virtual]. Check: lock.virtual->initial_availability"

kiowaro avatar Nov 03 '21 14:11 kiowaro

Ok, I will check if some breaking change was done to lock.

Tony763 avatar Nov 03 '21 14:11 Tony763

Fix proposed, my bad. Hi @twrecked, could you check PR, please.

Tony763 avatar Nov 03 '21 22:11 Tony763

The issue seems to be fixed. The lock is available after restart and adding the option "initial_availability: true" doesn't generate any config errors. Thanks.

kiowaro avatar Nov 04 '21 05:11 kiowaro