dahua icon indicating copy to clipboard operation
dahua copied to clipboard

continue_on_error implementation issue

Open hausmanconsulting opened this issue 1 year ago • 0 comments

I am using this integration to detect cross line and cross area detection on Amcrest cameras. Everything is working, except occasionally when I try to grab a snapshot from a camera I get a timeout error:

Error: TimeoutError
Result:

params:
  domain: camera
  service: snapshot
  service_data:
    filename: ./www/snapshots/driveway_camera_snapshot3.jpg
    entity_id:
      - camera.driveway_camera_main
  target:
    entity_id:
      - camera.driveway_camera_main
running_script: false

This is rare, but when it happens it stops my script in HA. I added "continue_on_error: true" to each action that grabs a snapshot, but it doesn't work. According to this link:

https://github.com/home-assistant/core/issues/115401#issuecomment-2408619871

The issue might be that this integration doesn't raise the HomeAssistantError when there is a problem, so HA stops the script anyway.

This is just a guess, but thought I'd mention it here in case anyone has any thoughts. I am trying to find a workaround that grabs snapshots more reliably, but if the script always fails on any error I don't see any way of making it run even if a snapshot fails.

hausmanconsulting avatar Oct 25 '24 17:10 hausmanconsulting