Aarghh…
I hardly ever check the calendar, since I made it more out of experimental curiosity, but now see this:
getting the events in the actions page results in:
Snippet of huge list
calendar.afvalwijzer:
events:
- start: "2024-08-28"
end: "2024-08-29"
summary: Ophaaldag Saver
description: Restafval
- start: "2024-08-28"
end: "2024-08-29"
summary: Ophaaldag Saver
description: Restafval
- start: "2024-08-28"
end: "2024-08-29"
summary: Ophaaldag Saver
description: Restafval
- start: "2024-08-28"
end: "2024-08-29"
summary: Ophaaldag Saver
description: Restafval
- start: "2024-08-28"
end: "2024-08-29"
summary: Ophaaldag Saver
description: Restafval
- start: "2024-08-28"
end: "2024-08-29"
summary: Ophaaldag Saver
description: Restafval
- start: "2024-08-28"
end: "2024-08-29"
summary: Ophaaldag Saver
description: Restafval
- start: "2024-08-28"
end: "2024-08-29"
summary: Ophaaldag Saver
description: Restafval
etcetc
Somehow there has been some active creation goin on ( I do have that automated, but don’t see how it would have happened), and ofc I need to delete those excessive amounts of identical events.
Any thoughts how to proceed?
this is the automation that made them, and ive set some extra conditions, and mode: single
automation:
- id: afvalwijzer_in_calendar
mode: single
trigger:
platform: state
entity_id:
- sensor.afvalwijzer_gft
- sensor.afvalwijzer_papier
- sensor.afvalwijzer_plastic
- sensor.afvalwijzer_restafval
# not_to: &un
# - unavailable
# - unknown
# not_from: *un
condition:
- !include /config/includes/include_from_to_not_un.yaml
- !include /config/includes/include_to_not_is_from.yaml
action:
- variables:
date: >
{{trigger.to_state.state}}
- service: calendar.create_event
target:
entity_id: calendar.afvalwijzer
data:
summary: Ophaaldag Saver
description: >
{{trigger.to_state.attributes.friendly_name}}
start_date: >
{{date}}
end_date: >
{{(as_datetime(date)+ timedelta(days=1))
|as_timestamp|timestamp_custom('%Y-%m-%d')}}
# {{(as_datetime(date)+ timedelta(days=1)).strftime('%Y-%m-%d')}}
- !include /config/includes/include_notify_developing_on.yaml
- service: notify.mobile_app_marijn
data:
title: Nieuwe data Afvalwijzer
message: >
Nieuwe data in kalender gezet voor
{{trigger.to_state.attributes.friendly_name}}
Op {{trigger.to_state.state}}