Service error message: blink.blink_update

Hello everyone, since the update to 2023.12.0. I have a problem with the “service: blink.blink_update”.

I always use the following script:

`alias: Kamera OG Bild machen
sequence:
  - service: blink.trigger_camera
    data:
      entity_id: camera.blink_g8t1gj0130160k0g_camera
  - delay: "00:00:05"
  - service: blink.blink_update
    data: {}
  - service: camera.snapshot
    data:
      filename: /config/www/snapshot/eg_tuer.jpg
    target:
      entity_id: camera.blink_g8t1gj0130160k0g_camera`

With automation, the camera is triggered once an hour and the image is updated and then the image is saved. This always worked reliably.

Since updating to HA 2023.12.0 I get the following two errors in the log and it no longer works. I currently assume that the error is triggered by this part of the code:

  - service: blink.blink_update
    data: {}

Here are the two errors from the log:

Logger: homeassistant.components.websocket_api.http.connection
Source: components/websocket_api/commands.py:238
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 10:14:39 (1 occurrences)
Last logged: 10:14:39

[546273803584] 'device_id'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 238, in handle_call_service
    response = await hass.services.async_call(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2067, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2104, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/script/__init__.py", line 605, in _service_handler
    response = await self._async_start_run(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/script/__init__.py", line 563, in _async_start_run
    script_result = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/script/__init__.py", line 594, in _async_run
    return await self.script.async_run(script_vars, context)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  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 2067, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2104, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/blink/services.py", line 150, in blink_refresh
    for coordinator in collect_coordinators(call.data[ATTR_DEVICE_ID]):
                                            ~~~~~~~~~^^^^^^^^^^^^^^^^
KeyError: 'device_id'
Logger: homeassistant.components.script.kamera_og_bild_machen
Source: helpers/script.py:468
Integration: Skript (documentation, issues)
First occurred: 10:14:39 (1 occurrences)
Last logged: 10:14:39

Kamera OG Bild machen: Error executing script. Unexpected error for call_service at pos 3: 'device_id'
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 2067, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2104, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/blink/services.py", line 150, in blink_refresh
    for coordinator in collect_coordinators(call.data[ATTR_DEVICE_ID]):
                                            ~~~~~~~~~^^^^^^^^^^^^^^^^
KeyError: 'device_id'

Does anyone here have an idea of what I need to change here to make it work again?

i have the same issue on my side

Started seeing same issue. The blink_update fails and causes automations to stop.

Same issue on my side

I just updated HA to 2024.1.3. At the moment it seems that the error with Blink is now fixed. The cameras have now been connected for 3 hours without interruption. Wait and see.