You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug and how to reproduce it:
I just called the action below from Developer tools
ACTION:
action: adaptive_lighting.change_switch_settings
data:
entity_id: switch.adaptive_lighting_adapt_brightness_living_room
min_brightness: "30"
use_defaults: current
Steps to reproduce the behavior:
The text was updated successfully, but these errors were encountered:
Home Assistant Adaptive Lighting Issue Template
Bug Reports
If you need help with using or configuring Adaptive Lighting, please open a Q&A discussion thread here instead.
Before submitting a bug report, please follow these troubleshooting steps:
Please confirm that you have completed the following steps:
See attached CSV.
Adaptives.csv
Key error is below
<style> </style>2024-09-28 22:09:27.758 ERROR (MainThread) [homeassistant.helpers.script.websocket_api_script] websocket_api script: Error executing script. Unexpected error for call_service at pos 1: 'SimpleSwitch' object has no attribute '_current_settings'
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 525, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 763, in _async_call_service_step
response_data = await self._async_run_long_action(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 726, in _async_run_long_action
return await long_task
^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2761, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2804, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 996, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1068, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/config/custom_components/adaptive_lighting/switch.py", line 360, in handle_change_switch_settings
defaults = switch._current_settings # pylint: disable=protected-access
^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'SimpleSwitch' object has no attribute '_current_settings'
2024-09-28 22:09:27.785 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140411163976480] Error handling message: Unknown error (unknown_error) Kirk from 192.168.11.4 (Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36)
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/decorators.py", line 28, in _handle_async_response
await func(hass, connection, msg)
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 816, in handle_execute_script
script_result = await script_obj.async_run(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1795, in async_run
return await asyncio.shield(create_eager_task(run.async_run()))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 463, in async_run
await self._async_step(log_exceptions=False)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 527, in _async_step
self._handle_exception(
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 557, in _handle_exception
raise exception
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 525, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 763, in _async_call_service_step
response_data = await self._async_run_long_action(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 726, in _async_run_long_action
return await long_task
^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2761, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2804, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 996, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1068, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/config/custom_components/adaptive_lighting/switch.py", line 360, in handle_change_switch_settings
defaults = switch._current_settings # pylint: disable=protected-access
^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'SimpleSwitch' object has no attribute '_current_settings'
Nothing more than the following in configuration.yaml. My config is set up in the UI.
adaptive_lighting:
Nil
Describe the bug and how to reproduce it:
I just called the action below from Developer tools
ACTION:
action: adaptive_lighting.change_switch_settings
data:
entity_id: switch.adaptive_lighting_adapt_brightness_living_room
min_brightness: "30"
use_defaults: current
Steps to reproduce the behavior:
The text was updated successfully, but these errors were encountered: