Since I updated to Home Assistant version 2023.11.1 I noticed that the script no longer works.
Can someone help me with my problem?
Logger: homeassistant.components.automation.good_night_house
Source: components/automation/__init__.py:655
Integration: Automatisierung (documentation, issues)
First occurred: 18:36:10 (1 occurrences)
Last logged: 18:36:10
While executing automation automation.good_night_house
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/automation/__init__.py", line 655, in async_trigger
await self.action_script.async_run(
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1578, in async_run
return await asyncio.shield(run.async_run())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 420, in async_run
await self._async_step(log_exceptions=False)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 470, in _async_step
self._handle_exception(
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 493, in _handle_exception
raise exception
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 468, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 704, in _async_call_service_step
response_data = await self._async_run_long_action(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 666, in _async_run_long_action
return long_task.result()
^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2035, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2072, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 235, in handle_service
return await service.entity_service_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 904, in entity_service_call
task.result() # pop exception if have
^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1219, in async_request_call
return await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 948, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 591, in async_handle_light_off_service
await light.async_turn_off(**filter_turn_off_params(light, params))
File "/usr/src/homeassistant/homeassistant/components/wled/helpers.py", line 28, in handler
await func(self, *args, **kwargs)
File "/usr/src/homeassistant/homeassistant/components/wled/light.py", line 208, in async_turn_off
await self.coordinator.wled.segment(
File "/usr/local/lib/python3.11/site-packages/wled/wled.py", line 515, in segment
await self.request("/json/state", method="POST", data=state)
File "/usr/local/lib/python3.11/site-packages/backoff/_async.py", line 151, in retry
ret = await target(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/wled/wled.py", line 211, in request
response_data = await response.json()
^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/aiohttp_client.py", line 84, in json
return await super().json(*args, loads=loads, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1120, in json
return loads(stripped.decode(encoding))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
orjson.JSONDecodeError: unexpected character: line 1 column 862 (char 861)
Logger: homeassistant.components.automation.good_night_house
Source: helpers/script.py:468
Integration: Automatisierung (documentation, issues)
First occurred: 18:36:10 (1 occurrences)
Last logged: 18:36:10
Good Night House: Error executing script. Unexpected error for call_service at pos 3: unexpected character: line 1 column 862 (char 861)
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 468, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 704, in _async_call_service_step
response_data = await self._async_run_long_action(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 666, in _async_run_long_action
return long_task.result()
^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2035, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2072, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 235, in handle_service
return await service.entity_service_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 904, in entity_service_call
task.result() # pop exception if have
^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1219, in async_request_call
return await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 948, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 591, in async_handle_light_off_service
await light.async_turn_off(**filter_turn_off_params(light, params))
File "/usr/src/homeassistant/homeassistant/components/wled/helpers.py", line 28, in handler
await func(self, *args, **kwargs)
File "/usr/src/homeassistant/homeassistant/components/wled/light.py", line 208, in async_turn_off
await self.coordinator.wled.segment(
File "/usr/local/lib/python3.11/site-packages/wled/wled.py", line 515, in segment
await self.request("/json/state", method="POST", data=state)
File "/usr/local/lib/python3.11/site-packages/backoff/_async.py", line 151, in retry
ret = await target(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/wled/wled.py", line 211, in request
response_data = await response.json()
^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/aiohttp_client.py", line 84, in json
return await super().json(*args, loads=loads, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1120, in json
return loads(stripped.decode(encoding))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
orjson.JSONDecodeError: unexpected character: line 1 column 862 (char 861)
automation:
##############################################################################################################################
### Restore Lights ### switch groups or other stuff ### Verwendung in automation.good_night_house
######################
restore_lights_on:
alias: Turn on a given selection of lights, saving current state
sequence:
- service: python_script.light_store
data:
store_name: flash_store
entity_id:
- light.bett_leds
- light.lampe_rgb_schlafzimmer
- light.schlafzimmer_deckenlampe
- light.lena_stehlampe
- light.sonoff_mini_lena
- light.tobias_zimmerlicht
- light.einfahrt_decken_lampe
- light.einfahrtlicht
- light.opel_licht
- light.einfahrt_decken_lampe_fake
- switch.kasten
- light.wled_badezimmer
- light.badezimmer_ikea_lampe
- light.badezimmer_deckenlampe
- light.nono_led
- light.og
- light.ttgo_neopixel_light
- light.matrix
- service: homeassistant.turn_on
restore_lights:
alias: Restore saved lights to the way they were
sequence:
- service: python_script.light_store
data:
store_name: flash_store
operation: restore