Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't save any new To Do items when system timezone is not valid timezone #112647

Closed
al-jimenez opened this issue Mar 7, 2024 · 45 comments · Fixed by #113034
Closed

Can't save any new To Do items when system timezone is not valid timezone #112647

al-jimenez opened this issue Mar 7, 2024 · 45 comments · Fixed by #113034

Comments

@al-jimenez
Copy link

al-jimenez commented Mar 7, 2024

The problem

Using Local To Do list integration. Created a new To Do list item, then I edited it to add a description; once I tried to save it (& I DID NOT specify a due date or time), I then received this error, which was also posted to syslog: "No timezone information available for event: {key}". I could NOT save the To Do item & discovered that I could start new items, but could not edit them. But... I was able to edit items that had been previously created. Just can't edit any new items.

What version of Home Assistant Core has the issue?

core-core-2024.3.0

What was the last working version of Home Assistant Core?

core-core-2024.2.5

What type of installation are you running?

Home Assistant Supervised

Integration causing the issue

Local To-do

Link to integration documentation on our website

https://www.home-assistant.io/integrations/local_todo

Diagnostics information

Attempted the above several times and kept getting the error. Checked my 'timezone' and it was correct:
(GMT-06:00) Central Time. I attempted to enter a due date and time, but still got the error. I was not able to save the To Do item so this basically means I cannot create any new To Do list items. NOTE: I was able to successfully edit and modify existing To Do items. Just not create any new ones. I have two To Do lists & and I could not create new items in either list.

Example YAML snippet

No response

Anything in the logs that might be useful for us?

Logger: homeassistant.components.websocket_api.http.connection
Source: components/websocket_api/commands.py:239
integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 1:40:31 PM (5 occurrences)
Last logged: 1:54:47 PM

[547421976384] No timezone information available for event: {key}
Traceback (most recent call last):
  File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 64, in _ensure_timezone
    return Timezone.from_tzif(key)
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ical/timezone.py", line 166, in from_tzif
    info = timezoneinfo.read(key)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ical/tzif/timezoneinfo.py", line 69, in read
    raise TimezoneInfoError(f"Unable to find timezone in system timezones: {key}")
ical.tzif.timezoneinfo.TimezoneInfoError: Unable to find timezone in system timezones: CST

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 239, in handle_call_service
    response = await hass.services.async_call(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2319, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2356, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 905, in entity_service_call
    single_response = await _handle_entity_call(
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 975, in _handle_entity_call
    result = await task
             ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/todo/__init__.py", line 511, in _async_update_todo_item
    await entity.async_update_todo_item(item=TodoItem(**updated_data))
  File "/usr/src/homeassistant/homeassistant/components/local_todo/todo.py", line 157, in async_update_todo_item
    TodoStore(self._calendar).edit(todo.uid, todo)
  File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 319, in edit
    self._apply_edit(
  File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 379, in _apply_edit
    self._ensure_timezone(new_item.dtstart)
  File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 394, in _ensure_timezone
    if (new_timezone := _ensure_timezone(dtstart, self._timezones)) is not None:
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 66, in _ensure_timezone
    raise EventStoreError(
ical.exceptions.EventStoreError: No timezone information available for event: {key}

Additional information

I had forgotten to mention that I had also restarted HA and tested again. Same result.

@home-assistant
Copy link

home-assistant bot commented Mar 7, 2024

Hey there @allenporter, mind taking a look at this issue as it has been labeled with an integration (local_todo) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of local_todo can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign local_todo Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


local_todo documentation
local_todo source
(message by IssueLinks)

@Jhonattan-Souza
Copy link

I'm with the same issue here

@Jhonattan-Souza
Copy link

#112605

@robferre
Copy link

robferre commented Mar 8, 2024

Also noticed that this error occurred too with one list after trying to apply due date. It also affected other local todos which in turn did not allow me to modify items. I didn't try to add due dates to the other lists ...

But then after a reboot, all local todos broke sand are unavailable. Reload of the device integration does not fix. Nor trying to use the get_items service. Adding new local todos works and can change those

Hope this also helps

@allenporter
Copy link
Contributor

allenporter commented Mar 8, 2024

@al-jimenez Thank you for the report.

Two tracks to explore here:

  • When this happens, i can make it less severe
  • Understanding the timezone mismatch
    • Can you tell me about the operating system you're using with home assistant core?
    • Are you folks all using CST as a timezone or something else?
    • Is this set from the Home Assistant UI, or from an environment variable, or configuration.yaml?
    • Context is: 'CST' is not a valid timezone for this library so it makes sense that it can't find it so wanting to know if this is an incompatibility between libraries or a misconfiguration

@allenporter allenporter added this to the 2024.3.1 milestone Mar 8, 2024
@al-jimenez
Copy link
Author

al-jimenez commented Mar 8, 2024

@allenporter

  • I am running HA Supervised on a Raspberry Pi 4. Operation System version 12.0, Supervisor version 2024.02.1.
  • CST was established in configuration.yaml (1st installed) but I went to the UI setting to update it during my initial testing of the issue
  • My entry in configuration.yaml is not CST but its 'time_zone: "America/Chicago"' ; when I updated it in the UI is showed up as 'Time zone =(GMT-06:00) Central Time'. My mistake in refering to it as CST and not being more explicit.

@allenporter
Copy link
Contributor

Ok thanks that is super helpful. The error message is
ical.tzif.timezoneinfo.TimezoneInfoError: Unable to find timezone in system timezones: CST

So it's getting to CST somewhere. I'll try to reproduce. Thanks!

@al-jimenez
Copy link
Author

al-jimenez commented Mar 8, 2024

NOTE: additional info:

In Developer Tools | Template, I enter the following to verify:

Timezone: {{ now().tzinfo }}
offset:   {{ now().isoformat()[-6:] }}

And got:

Timezone: America/Chicago
offset:   -06:00

An important note on the severity of the issue: is that I cannot create and edit any new to-do items. I can start one but as soon as I try to edit one I get the error and can't modify it. But curious thing is I can modify older pre-existing To-do items. ¯_(ツ)_/¯

Hope this helps.

@transplier
Copy link

I'm having the same issue. I don't have timezone set in configuration.yaml, just through the UI. For me, the template in the above comment expands to:

Timezone: America/Los_Angeles
offset:   -08:00

I've got it set to (GMT-08:00) Pacific Time in the UI.

@allenporter
Copy link
Contributor

I have not yet been able to reproduce this myself to get to the bottom of it.

Do you happen to use local calendar? I am curious if you also see problems there. If you happen to use local calendar and can get a diagnostics entry that would help get some debug information that isn't yet included in local todo.

@transplier
Copy link

I don't use local calendar but I do have a couple calendar helpers. I'm not sure if those are related?

@al-jimenez
Copy link
Author

I do not have the 'local calendar' integration installed and don't use any calendars.

@al-jimenez
Copy link
Author

al-jimenez commented Mar 9, 2024

❗️I installed the 'Local Calendar'. I created an event without issue BUT, when I attempted to edit the event I received the following error:

Unable to parse date/time value: [ValueError("Expected value to match DATE pattern: ''"), ValueError('Expected value to match DATE-TIME pattern: ')]

So it would seem the issue may not be specifically related to 'Local To-do'

@allenporter
Copy link
Contributor

@al-jimenez yeah sorry that's #112716 which i fixed for an upcoming patch release. What would be helpful here is if you get the diagnostics ("download diagnostics") for it as it includes detailed timezone information which is also relevant to the todo integration.

@al-jimenez
Copy link
Author

Here is the diagnostic log:

`2024-03-09 09:37:46.220 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration watchman which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-03-09 09:37:46.222 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration hacs which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-03-09 09:38:05.163 WARNING (MainThread) [homeassistant.setup] Setup of input_button is taking over 10 seconds.
2024-03-09 09:38:05.163 WARNING (MainThread) [homeassistant.setup] Setup of counter is taking over 10 seconds.
2024-03-09 09:38:08.833 WARNING (MainThread) [homeassistant.setup] Setup of zone is taking over 10 seconds.
2024-03-09 09:38:08.836 WARNING (MainThread) [homeassistant.setup] Setup of input_datetime is taking over 10 seconds.
2024-03-09 09:38:08.837 WARNING (MainThread) [homeassistant.setup] Setup of input_select is taking over 10 seconds.
2024-03-09 09:38:08.837 WARNING (MainThread) [homeassistant.setup] Setup of input_boolean is taking over 10 seconds.
2024-03-09 09:38:08.837 WARNING (MainThread) [homeassistant.setup] Setup of timer is taking over 10 seconds.
2024-03-09 09:38:11.113 WARNING (MainThread) [homeassistant.helpers.frame] Detected that custom integration 'hacs' accesses hass.components.frontend. This is deprecated and will stop working in Home Assistant 2024.9, it should be updated to import functions used from frontend directly at custom_components/hacs/frontend.py, line 68: hass.components.frontend.async_register_built_in_panel(, please create a bug report at https://github.com/hacs/integration/issues
2024-03-09 09:40:35.367 DEBUG (MainThread) [ical.component] Parsing value data {'summary': 'Test #2 ', 'description': 'Testing again', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:40:35.368 DEBUG (MainThread) [ical.component] Completed parsing value data {'summary': 'Test #2 ', 'description': 'Testing again', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:40:35.368 DEBUG (MainThread) [ical.event] Found initial values dtstart=2024-03-23 09:00:00, dtend=2024-03-23 10:00:00
2024-03-09 09:40:35.369 DEBUG (MainThread) [ical.store] Adding item: dtstamp=datetime.datetime(2024, 3, 9, 15, 40, 35, 368896) uid='5efd6774-de2b-11ee-b3c2-e45f0165ad0e' dtstart=datetime.datetime(2024, 3, 23, 9, 0) dtend=datetime.datetime(2024, 3, 23, 10, 0) duration=None summary='Test #2 ' attendees=[] categories=[] classification=None comment=[] contacts=[] created=datetime.datetime(2024, 3, 9, 15, 40, 35, 368896) description='Testing again' geo=None last_modified=None location=None organizer=None priority=None recurrence_id=None related_to=[] related=[] resources=[] rrule=None rdate=[] exdate=[] request_status=None sequence=0 status=None transparency=None url=None extras=[] alarm=[]
2024-03-09 09:40:35.375 DEBUG (MainThread) [ical.component] Parsing value data {'vcalendar': [Calendar(calscale=None, method=None, prodid='-//homeassistant.io//local_calendar 1.0//EN', version='2.0', events=[Event(dtstamp=datetime.datetime(2024, 3, 9, 15, 24, 19), uid='1936ab08-de29-11ee-b5ce-e45f0165ad0e', dtstart=datetime.datetime(2024, 3, 16, 9, 0), dtend=datetime.datetime(2024, 3, 16, 10, 0), duration=None, summary='Test event', attendees=[], categories=[], classification=None, comment=[], contacts=[], created=datetime.datetime(2024, 3, 9, 15, 24, 19), description='This is a test', geo=None, last_modified=None, location=None, organizer=None, priority=None, recurrence_id=None, related_to=[], related=[], resources=[], rrule=None, rdate=[], exdate=[], request_status=None, sequence=0, status=None, transparency=None, url=None, extras=[], alarm=[]), Event(dtstamp=datetime.datetime(2024, 3, 9, 15, 40, 35, 368896), uid='5efd6774-de2b-11ee-b3c2-e45f0165ad0e', dtstart=datetime.datetime(2024, 3, 23, 9, 0), dtend=datetime.datetime(2024, 3, 23, 10, 0), duration=None, summary='Test #2 ', attendees=[], categories=[], classification=None, comment=[], contacts=[], created=datetime.datetime(2024, 3, 9, 15, 40, 35, 368896), description='Testing again', geo=None, last_modified=None, location=None, organizer=None, priority=None, recurrence_id=None, related_to=[], related=[], resources=[], rrule=None, rdate=[], exdate=[], request_status=None, sequence=0, status=None, transparency=None, url=None, extras=[], alarm=[])], todos=[], journal=[], freebusy=[], timezones=[], extras=[])]}
2024-03-09 09:40:35.376 DEBUG (MainThread) [ical.component] Completed parsing value data {'vcalendar': [Calendar(calscale=None, method=None, prodid='-//homeassistant.io//local_calendar 1.0//EN', version='2.0', events=[Event(dtstamp=datetime.datetime(2024, 3, 9, 15, 24, 19), uid='1936ab08-de29-11ee-b5ce-e45f0165ad0e', dtstart=datetime.datetime(2024, 3, 16, 9, 0), dtend=datetime.datetime(2024, 3, 16, 10, 0), duration=None, summary='Test event', attendees=[], categories=[], classification=None, comment=[], contacts=[], created=datetime.datetime(2024, 3, 9, 15, 24, 19), description='This is a test', geo=None, last_modified=None, location=None, organizer=None, priority=None, recurrence_id=None, related_to=[], related=[], resources=[], rrule=None, rdate=[], exdate=[], request_status=None, sequence=0, status=None, transparency=None, url=None, extras=[], alarm=[]), Event(dtstamp=datetime.datetime(2024, 3, 9, 15, 40, 35, 368896), uid='5efd6774-de2b-11ee-b3c2-e45f0165ad0e', dtstart=datetime.datetime(2024, 3, 23, 9, 0), dtend=datetime.datetime(2024, 3, 23, 10, 0), duration=None, summary='Test #2 ', attendees=[], categories=[], classification=None, comment=[], contacts=[], created=datetime.datetime(2024, 3, 9, 15, 40, 35, 368896), description='Testing again', geo=None, last_modified=None, location=None, organizer=None, priority=None, recurrence_id=None, related_to=[], related=[], resources=[], rrule=None, rdate=[], exdate=[], request_status=None, sequence=0, status=None, transparency=None, url=None, extras=[], alarm=[])], todos=[], journal=[], freebusy=[], timezones=[], extras=[])]}
2024-03-09 09:40:51.181 DEBUG (MainThread) [ical.component] Parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:40:51.182 DEBUG (MainThread) [ical.component] Completed parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:40:51.182 DEBUG (MainThread) [ical.event] Found initial values dtstart=2024-03-23 09:00:00, dtend=2024-03-23 10:00:00
2024-03-09 09:40:51.183 DEBUG (MainThread) [ical.store] Expanding item 5efd6774-de2b-11ee-b3c2-e45f0165ad0e 2024-03-23 09:00:00 to look for match of
2024-03-09 09:40:51.183 ERROR (MainThread) [homeassistant.components.calendar] Error handling Calendar Event call: Unable to parse date/time value: [ValueError("Expected value to match DATE pattern: ''"), ValueError('Expected value to match DATE-TIME pattern: ')]
2024-03-09 09:40:58.529 DEBUG (MainThread) [ical.component] Parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:40:58.529 DEBUG (MainThread) [ical.component] Completed parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:40:58.529 DEBUG (MainThread) [ical.event] Found initial values dtstart=2024-03-23 09:00:00, dtend=2024-03-23 10:00:00
2024-03-09 09:40:58.530 DEBUG (MainThread) [ical.store] Expanding item 5efd6774-de2b-11ee-b3c2-e45f0165ad0e 2024-03-23 09:00:00 to look for match of
2024-03-09 09:40:58.531 ERROR (MainThread) [homeassistant.components.calendar] Error handling Calendar Event call: Unable to parse date/time value: [ValueError("Expected value to match DATE pattern: ''"), ValueError('Expected value to match DATE-TIME pattern: ')]
2024-03-09 09:41:00.261 DEBUG (MainThread) [ical.component] Parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:41:00.261 DEBUG (MainThread) [ical.component] Completed parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:41:00.261 DEBUG (MainThread) [ical.event] Found initial values dtstart=2024-03-23 09:00:00, dtend=2024-03-23 10:00:00
2024-03-09 09:41:00.262 DEBUG (MainThread) [ical.store] Expanding item 5efd6774-de2b-11ee-b3c2-e45f0165ad0e 2024-03-23 09:00:00 to look for match of
2024-03-09 09:41:00.262 ERROR (MainThread) [homeassistant.components.calendar] Error handling Calendar Event call: Unable to parse date/time value: [ValueError("Expected value to match DATE pattern: ''"), ValueError('Expected value to match DATE-TIME pattern: ')]
2024-03-09 09:41:00.558 DEBUG (MainThread) [ical.component] Parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:41:00.559 DEBUG (MainThread) [ical.component] Completed parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:41:00.559 DEBUG (MainThread) [ical.event] Found initial values dtstart=2024-03-23 09:00:00, dtend=2024-03-23 10:00:00
2024-03-09 09:41:00.559 DEBUG (MainThread) [ical.store] Expanding item 5efd6774-de2b-11ee-b3c2-e45f0165ad0e 2024-03-23 09:00:00 to look for match of
2024-03-09 09:41:00.560 ERROR (MainThread) [homeassistant.components.calendar] Error handling Calendar Event call: Unable to parse date/time value: [ValueError("Expected value to match DATE pattern: ''"), ValueError('Expected value to match DATE-TIME pattern: ')]
2024-03-09 09:41:00.847 DEBUG (MainThread) [ical.component] Parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:41:00.847 DEBUG (MainThread) [ical.component] Completed parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:41:00.847 DEBUG (MainThread) [ical.event] Found initial values dtstart=2024-03-23 09:00:00, dtend=2024-03-23 10:00:00
2024-03-09 09:41:00.848 DEBUG (MainThread) [ical.store] Expanding item 5efd6774-de2b-11ee-b3c2-e45f0165ad0e 2024-03-23 09:00:00 to look for match of
2024-03-09 09:41:00.848 ERROR (MainThread) [homeassistant.components.calendar] Error handling Calendar Event call: Unable to parse date/time value: [ValueError("Expected value to match DATE pattern: ''"), ValueError('Expected value to match DATE-TIME pattern: ')]
2024-03-09 09:41:01.112 DEBUG (MainThread) [ical.component] Parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:41:01.113 DEBUG (MainThread) [ical.component] Completed parsing value data {'summary': 'Test #2 ', 'description': 'Testing again.... testing editing', 'dtstart': datetime.datetime(2024, 3, 23, 9, 0), 'dtend': datetime.datetime(2024, 3, 23, 10, 0)}
2024-03-09 09:41:01.113 DEBUG (MainThread) [ical.event] Found initial values dtstart=2024-03-23 09:00:00, dtend=2024-03-23 10:00:00
2024-03-09 09:41:01.114 DEBUG (MainThread) [ical.store] Expanding item 5efd6774-de2b-11ee-b3c2-e45f0165ad0e 2024-03-23 09:00:00 to look for match of
2024-03-09 09:41:01.114 ERROR (MainThread) [homeassistant.components.calendar] Error handling Calendar Event call: Unable to parse date/time value: [ValueError("Expected value to match DATE pattern: ''"), ValueError('Expected value to match DATE-TIME pattern: ')]
2024-03-09 09:43:29.079 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [547390934464] No timezone information available for event: {key}
Traceback (most recent call last):
File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 64, in _ensure_timezone
return Timezone.from_tzif(key)
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/ical/timezone.py", line 166, in from_tzif
info = timezoneinfo.read(key)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/ical/tzif/timezoneinfo.py", line 69, in read
raise TimezoneInfoError(f"Unable to find timezone in system timezones: {key}")
ical.tzif.timezoneinfo.TimezoneInfoError: Unable to find timezone in system timezones: CST

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 239, in handle_call_service
response = await hass.services.async_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2319, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2356, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 905, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 975, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/todo/init.py", line 511, in _async_update_todo_item
await entity.async_update_todo_item(item=TodoItem(**updated_data))
File "/usr/src/homeassistant/homeassistant/components/local_todo/todo.py", line 157, in async_update_todo_item
TodoStore(self._calendar).edit(todo.uid, todo)
File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 319, in edit
self._apply_edit(
File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 379, in _apply_edit
self._ensure_timezone(new_item.dtstart)
File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 394, in _ensure_timezone
if (new_timezone := _ensure_timezone(dtstart, self._timezones)) is not None:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/ical/store.py", line 66, in _ensure_timezone
raise EventStoreError(
ical.exceptions.EventStoreError: No timezone information available for event: {key}
`

@allenporter
Copy link
Contributor

Can you see the "Download diagnostics" in the link i provided? It is something different from the logs.

@al-jimenez
Copy link
Author

Yes, that process is what I used for the above.

@allenporter
Copy link
Contributor

Those are logs, the diagnostics section is a little lower ( I may have linked too high)

@al-jimenez
Copy link
Author

When I asked it to download diagnostics log it included all of this. Only the last portion really applies to the issue, not sure why it included all the other stuff.

@allenporter
Copy link
Contributor

Diagnostics gives you a file to download and attach as shown in this screenshot https://www.home-assistant.io/docs/configuration/troubleshooting/#download-diagnostics (different from enabling debugging and the log contents that is pasted above)

@al-jimenez
Copy link
Author

al-jimenez commented Mar 9, 2024

Yeah, I enable diag logging, reproduced the issue to get the error, I then disable diag logging and the diag file downloads to my local folder (auto downloaded once I disable diag logging). That is what I pasted above. (I DO NOT get the 'Download Diagnostics' menu item though). The '[homeassistant.loader] ', '[homeassistant.setup]' & 'ical.component]' entries in the file is prepended to the diag file and seems to have been included in it.

@allenporter
Copy link
Contributor

To clarify: You're saying "diag logging" (which is really "debug logging") which is not what i'm asking for. I am asking for "Download Diagnostics" for local calendar.

@al-jimenez
Copy link
Author

Yes, sorry for that, diag logging = debug logging. And yes that is the file I provided above. Attached here:
home-assistant_local_todo_2024-03-09T15-58-44.986Z.log

@allenporter
Copy link
Contributor

We seem to be misunderstanding each other. To clarify:

  • I am not asking for debug logging or any logging.
  • I am asking for "Download Diagnostics" for local calendar.

Here is a screenshot of what i'm talking about:
Screenshot 2024-03-09 at 10 33 15 AM

Which is the same as this: https://www.home-assistant.io/docs/configuration/troubleshooting/#download-diagnostics

@al-jimenez
Copy link
Author

@Jens5395
Copy link

Jens5395 commented Mar 9, 2024

I also ran into the 'timezone not found' issue. I tried to reboot the HA computer and now two of my four lists are missing. They are there if I look at the local to-do integration but are not there if I look at 'to-do lists'. I have no idea what happened to the data or where I could find it to re-create the lists

@NightWatchman
Copy link

NightWatchman commented Mar 9, 2024

I am having this issue as well on v2024.3. I got the timezone issue. I tried to roll back to v2024.2, but it just made two of my todo lists dissapear once the system came back up. I updated back to v2024.3 and they're still missing.

Not sure if it's related, but my timezone America/Los_Angeles daylight savings changes on the 10th.

@andreprandina
Copy link

andreprandina commented Mar 9, 2024

Same here. TZ issues with todo. Deleted 2 of my three lists. I did set the state of the two unavailable lists manually, and they got back, but after that, they can´t receive new entrys. Then a I deleted both unavailable lists and create new ones. Again, TZ issues. I do have local calendar. TZ gmt -03:00 São Paulo BR

@evitaer
Copy link

evitaer commented Mar 10, 2024

I have a similar issue, I started with this notice, shown in the photo, when I ticked off as complete the new items, that I had just added. It also had the same issue if I edited the item description. It progressed to not being able to add new items to the list, then it wiped my list from existence.

todo issues

When I restored it to the previous backup, the list came back, but with the first issue. Where I could add a new item, but it could not be completed or updated.

I haven't had an issue with list items that were existing prior to the update, just new list items on any of my lists. (it is the same with all my todo lists.)

I'm using pacific time zone, if that helps.

image

New Todo lists created after the update have the same bug as well. They also continue to have the issue after the roll back.

@allenporter
Copy link
Contributor

Thanks, I think i have enough information for a workaround even though I can't reproduce it myself yet. The new home assistant is writing date entries with timezones that are not found by the timezone library (old or new) so it makes sense why rollback doesn't help.

I'll make a patch to simply ignore the invalid timezone entries for now, then we can clean them up later and get them repaired in another pass after that once I can reproduce.

@allenporter
Copy link
Contributor

Thank you, the diagnostics show what I was looking for. The problem is the timezone information is coming from the system timezone and not the home assistant timezone:

  "data": {
    "now": "2024-03-09T12:36:54.958677-06:00",
    "timezone": "America/Chicago",
    "system_timezone": "CST",

@allenporter
Copy link
Contributor

I'm going to tackle this way:

  • attempt to reproduce it
  • see if i can prevent it for new use cases
  • repair for existing cases with invalid timezones written into the calendar

Thanks for your patience folks

@allenporter allenporter changed the title Can't save any new To Do items when I attempt to edit them to add a description. Can't save any new To Do items when system timezone is not valid timezone Mar 11, 2024
@jdrobertson-github
Copy link

Allen, thanks for looking into this. I have the same issue but my HA Timezone is the same as the System Timezone (as below) so I'm not sure if that is the issue. I too have only noticed this issue since 2024.3 if that helps.

Timezone: Australia/Brisbane
offset: +10:00
system_timezone: Australia/Brisbane

@codemannh
Copy link

Just wanted to add that I am having both of these issues, one with the local Todo list and the local calendar. I am running HA on a docker container on linux which is an LXC on Proxmox. The Linux container shows the TZ as CDT -0500. Wanted to keep an eye on the resolution. Appreciate you looking into it.

@allenporter
Copy link
Contributor

The fix is scheduled for the 2023.3.1 patch release.

@al-jimenez
Copy link
Author

I know this issue is closed and the fix seems like a reasonable fix. But quick question. I just updated to Supervisor 2024.03.0 and lost one of the Todo lists. It had quite a number of items; will there be a way to restore those once the fix deployed?

Thanks very much @allenporter for all your work on getting this issue resolved.

@allenporter
Copy link
Contributor

Yes, I will ensure the content is restorable with no action on your part. I recommend not touching it and we can circle back. If 2024.3.1 does not solve your issue open a new issue report filling out the full issue template and we will get to the bottom of it. (That said,my intention is that it's fixed in this patch, but just elaborating to answer your question)

@aegjoyce
Copy link

aegjoyce commented Mar 13, 2024

Posting here as I think this might be the same issue but different flavour...

2024.3.0, HAOS, have started using todo lists. I have been using nodered to automatically assign due dates to new and completed tasks using the API node, sending in the YYYY-MM-DD format. This has been working fine up until I had restart just now - now the integration won't load and gives the following error:

Logger: homeassistant.components.todo
Source: helpers/entity_platform.py:350
integration: To-do list (documentation, issues)
First occurred: 17:07:50 (3 occurrences)
Last logged: 17:07:50

Error while setting up local_todo platform for todo
Traceback (most recent call last):
  File "/usr/local/lib/python3.12/site-packages/ical/component.py", line 139, in __init__
    super().__init__(**data)
  File "/usr/local/lib/python3.12/site-packages/pydantic/main.py", line 341, in __init__
    raise validation_error
pydantic.error_wrappers.ValidationError: 2 validation errors for Todo
__root__
  can't compare datetime.datetime to datetime.date (type=type_error)
__root__
  Unexpected dtstart value '2024-03-09 21:16:11+00:00' was datetime but dtend value '2024-03-13' was not datetime (type=value_error)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 350, in _async_setup_platform
    await asyncio.shield(awaitable)
  File "/usr/src/homeassistant/homeassistant/components/local_todo/todo.py", line 71, in async_setup_entry
    calendar = IcsCalendarStream.calendar_from_ics(ics)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ical/calendar_stream.py", line 82, in calendar_from_ics
    stream = cls.from_ics(content)
             ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ical/calendar_stream.py", line 69, in from_ics
    return cls(**result)
           ^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ical/component.py", line 139, in __init__
    super().__init__(**data)
  File "/usr/local/lib/python3.12/site-packages/pydantic/main.py", line 339, in __init__
    values, fields_set, validation_error = validate_model(__pydantic_self__.__class__, data)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/main.py", line 1076, in validate_model
    v_, errors_ = field.validate(value, values, loc=field.alias, cls=cls_)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 895, in validate
    v, errors = self._validate_sequence_like(v, values, loc, cls)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 928, in _validate_sequence_like
    r, ee = self._validate_singleton(v_, values, v_loc, cls)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 1094, in _validate_singleton
    value, error = field.validate(v, values, loc=loc, cls=cls)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 884, in validate
    v, errors = self._validate_singleton(v, values, loc, cls)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 1101, in _validate_singleton
    return self._apply_validators(v, values, loc, cls, self.validators)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 1157, in _apply_validators
    v = validator(cls, v, values, self, self.model_config)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/class_validators.py", line 337, in <lambda>
    return lambda cls, v, values, field, config: validator(v)
                                                 ^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/main.py", line 711, in validate
    return cls(**value)
           ^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ical/component.py", line 139, in __init__
    super().__init__(**data)
  File "/usr/local/lib/python3.12/site-packages/pydantic/main.py", line 339, in __init__
    values, fields_set, validation_error = validate_model(__pydantic_self__.__class__, data)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/main.py", line 1076, in validate_model
    v_, errors_ = field.validate(value, values, loc=field.alias, cls=cls_)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 895, in validate
    v, errors = self._validate_sequence_like(v, values, loc, cls)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 928, in _validate_sequence_like
    r, ee = self._validate_singleton(v_, values, v_loc, cls)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 1094, in _validate_singleton
    value, error = field.validate(v, values, loc=loc, cls=cls)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 884, in validate
    v, errors = self._validate_singleton(v, values, loc, cls)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 1101, in _validate_singleton
    return self._apply_validators(v, values, loc, cls, self.validators)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/fields.py", line 1157, in _apply_validators
    v = validator(cls, v, values, self, self.model_config)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/class_validators.py", line 337, in <lambda>
    return lambda cls, v, values, field, config: validator(v)
                                                 ^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pydantic/main.py", line 711, in validate
    return cls(**value)
           ^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/ical/todo.py", line 203, in __init__
    super().__init__(**data)
  File "/usr/local/lib/python3.12/site-packages/ical/component.py", line 141, in __init__
    raise CalendarParseError(f"Failed to parse component: {err}") from err
ical.exceptions.CalendarParseError: Failed to parse component: 2 validation errors for Todo
__root__
  can't compare datetime.datetime to datetime.date (type=type_error)
__root__
  Unexpected dtstart value '2024-03-09 21:16:11+00:00' was datetime but dtend value '2024-03-13' was not datetime (type=value_error)

This looks like it might be part of the same issue as above, but brought on in a different way - what do you think? My plan of attack is to just leave it and see if 2024.3.1 fixes it too.

It could be my nodered flow I guess, but I don't think it is - here it is just in case:
[{"id":"949196be916a8bda","type":"tab","label":"Tasks","disabled":false,"info":"","env":[]},{"id":"f1d7a87b7aa9d635","type":"trigger-state","z":"949196be916a8bda","name":"change","server":"c4920a33.918dc8","version":4,"inputs":0,"outputs":2,"exposeAsEntityConfig":"","entityId":"todo.weekly","entityIdType":"exact","debugEnabled":false,"constraints":[],"customOutputs":[],"outputInitially":false,"stateType":"str","enableInput":false,"x":70,"y":200,"wires":[["f9d240ed3ca0a5d8"],[]]},{"id":"9577ec62b40b760c","type":"api-call-service","z":"949196be916a8bda","name":"assign due date","server":"c4920a33.918dc8","version":5,"debugenabled":false,"domain":"todo","service":"update_item","areaId":[],"deviceId":[],"entityId":[],"data":"{\"item\":\"{{payload.new_state.summary}}\",\"due_date\":\"{{due}}\",\"entity_id\":\"todo.weekly\"}","dataType":"json","mergeContext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":1540,"y":200,"wires":[["2293bf6a8d604e38"]]},{"id":"c1c8591ba9b6d7d0","type":"moment","z":"949196be916a8bda","name":"get due date","topic":"","input":"","inputType":"date","inTz":"Europe/London","adjAmount":"7","adjType":"days","adjDir":"add","format":"YYYY-MM-DD","locale":"C","output":"due","outputType":"msg","outTz":"Europe/London","x":1370,"y":200,"wires":[["9577ec62b40b760c"]]},{"id":"7b409971bf7b4b05","type":"switch","z":"949196be916a8bda","name":"saved data?","property":"#:(store)::weekly","propertyType":"flow","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":330,"y":200,"wires":[["0a639985d671edd7"],["e832f21643f711d2"]]},{"id":"0a639985d671edd7","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::weekly","pt":"flow","to":"payload.response[\"todo.weekly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":490,"y":160,"wires":[[]]},{"id":"f9d240ed3ca0a5d8","type":"ha-api","z":"949196be916a8bda","name":"","server":"c4920a33.918dc8","version":1,"debugenabled":false,"protocol":"websocket","method":"get","path":"","data":"{\t \"type\": \"execute_script\",\t \"sequence\": [\t {\t \"service\" : \"todo.get_items\",\t \"target\" : {\t \"entity_id\" : \"todo.weekly\"\t },\t \"data\" : {\t \"status\": [\"needs_action\", \"completed\"]\t },\t \"response_variable\" : \"service_result\"\t },\t {\t \"stop\" : \"done\",\t \"response_variable\": \"service_result\"\t }\t ]\t}","dataType":"jsonata","responseType":"json","outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"results"}],"x":190,"y":200,"wires":[["7b409971bf7b4b05"]]},{"id":"e832f21643f711d2","type":"change","z":"949196be916a8bda","name":"load saved","rules":[{"t":"set","p":"weekly","pt":"msg","to":"#:(store)::weekly","tot":"flow"}],"action":"","property":"","from":"","to":"","reg":false,"x":510,"y":200,"wires":[["3eac164916690352"]]},{"id":"3eac164916690352","type":"function","z":"949196be916a8bda","name":"get changes","func":"function compareArrays(newArray, oldArray) {\n let changes = [];\n\n newArray.forEach(newItem => {\n let oldItem = oldArray.find(item => item.uid === newItem.uid);\n if (!oldItem) {\n changes.push({\n old_state: null,\n new_state: newItem\n });\n } else if (JSON.stringify(oldItem) !== JSON.stringify(newItem)) {\n changes.push({\n old_state: oldItem,\n new_state: newItem\n });\n }\n });\n\n return changes;\n}\n\nlet newArray = msg.payload.response[\"todo.weekly\"].items;\nlet oldArray = msg.weekly;\n\nmsg.changes = compareArrays(newArray, oldArray);\n\nreturn msg;\n","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":670,"y":200,"wires":[["a268c9b395f9204c","a31143d9fb577532"]]},{"id":"8ff07e77fd7a0bcd","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::weekly","pt":"flow","to":"payload.response[\"todo.weekly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1810,"y":200,"wires":[[]]},{"id":"ae401f9c442c6ce0","type":"switch","z":"949196be916a8bda","name":"new item?","property":"payload.old_state","propertyType":"msg","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1010,"y":200,"wires":[["06efa2dedcf61ff3"],["7b42e91eda3f02c6"]]},{"id":"2293bf6a8d604e38","type":"ha-api","z":"949196be916a8bda","name":"","server":"c4920a33.918dc8","version":1,"debugenabled":false,"protocol":"websocket","method":"get","path":"","data":"{\t \"type\": \"execute_script\",\t \"sequence\": [\t {\t \"service\" : \"todo.get_items\",\t \"target\" : {\t \"entity_id\" : \"todo.weekly\"\t },\t \"data\" : {\t \"status\": [\"needs_action\", \"completed\"]\t },\t \"response_variable\" : \"service_result\"\t },\t {\t \"stop\" : \"done\",\t \"response_variable\": \"service_result\"\t }\t ]\t}","dataType":"jsonata","responseType":"json","outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"results"}],"x":1690,"y":200,"wires":[["8ff07e77fd7a0bcd"]]},{"id":"7b42e91eda3f02c6","type":"switch","z":"949196be916a8bda","name":"changed status?","property":"payload.new_state.status","propertyType":"msg","rules":[{"t":"neq","v":"payload.old_state.status","vt":"msg"}],"checkall":"true","repair":false,"outputs":1,"x":1030,"y":260,"wires":[["e7cb869c2c1dc09b"]]},{"id":"e7cb869c2c1dc09b","type":"switch","z":"949196be916a8bda","name":"new status?","property":"payload.new_state.status","propertyType":"msg","rules":[{"t":"eq","v":"completed","vt":"str"},{"t":"eq","v":"needs_action","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":1210,"y":260,"wires":[["c1c8591ba9b6d7d0"],[]]},{"id":"a31143d9fb577532","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::weekly","pt":"flow","to":"payload.response[\"todo.weekly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":810,"y":160,"wires":[[]]},{"id":"a268c9b395f9204c","type":"function","z":"949196be916a8bda","name":"split and send","func":"for (var i = 0; i < msg.changes.length; i++) {\n var newMsg = {};\n newMsg.payload = msg.changes[i];\n node.send(newMsg);\n}\nreturn null;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":840,"y":200,"wires":[["ae401f9c442c6ce0"]]},{"id":"06efa2dedcf61ff3","type":"switch","z":"949196be916a8bda","name":"has date?","property":"payload.new_state.due","propertyType":"msg","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1200,"y":200,"wires":[["c1c8591ba9b6d7d0"],[]]},{"id":"e377512aa69ad554","type":"trigger-state","z":"949196be916a8bda","name":"0000","server":"c4920a33.918dc8","version":4,"inputs":0,"outputs":2,"exposeAsEntityConfig":"","entityId":"sensor.time","entityIdType":"exact","debugEnabled":false,"constraints":[{"targetType":"this_entity","targetValue":"","propertyType":"current_state","propertyValue":"new_state.state","comparatorType":"is","comparatorValueDatatype":"str","comparatorValue":"00:00"}],"customOutputs":[],"outputInitially":false,"stateType":"str","enableInput":false,"x":70,"y":800,"wires":[["67a71756332e252b"],[]]},{"id":"67a71756332e252b","type":"ha-api","z":"949196be916a8bda","name":"","server":"c4920a33.918dc8","version":1,"debugenabled":false,"protocol":"websocket","method":"get","path":"","data":"{\t \"type\": \"execute_script\",\t \"sequence\": [\t {\t \"service\" : \"todo.get_items\",\t \"target\" : {\t \"entity_id\" : [\"todo.weekly\", \"todo.fortnightly\", \"todo.monthly\"]\t },\t \"data\" : {\t \"status\": \"completed\"\t },\t \"response_variable\" : \"service_result\"\t },\t {\t \"stop\" : \"done\",\t \"response_variable\": \"service_result\"\t }\t ]\t}","dataType":"jsonata","responseType":"json","outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"results"}],"x":190,"y":800,"wires":[["41b47164fdaf5d41"]]},{"id":"41b47164fdaf5d41","type":"function","z":"949196be916a8bda","name":"split and send","func":"var categories = [\"todo.weekly\", \"todo.fortnightly\", \"todo.monthly\"];\n\nfor (var c = 0; c < categories.length; c++) {\n var category = categories[c];\n for (var i = 0; i < msg.payload.response[category].items.length; i++) {\n var newMsg = {};\n newMsg.payload = msg.payload.response[category].items[i];\n newMsg.list = category;\n node.send(newMsg);\n }\n}\n\nreturn null;\n","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":340,"y":800,"wires":[["55526e2be9cf076d"]]},{"id":"55526e2be9cf076d","type":"moment","z":"949196be916a8bda","name":"time","topic":"","input":"","inputType":"date","inTz":"Europe/London","adjAmount":0,"adjType":"days","adjDir":"add","format":"YYYY-MM-DD","locale":"C","output":"time","outputType":"msg","outTz":"Europe/London","x":490,"y":800,"wires":[["8d33daa83cb05950"]]},{"id":"8d33daa83cb05950","type":"function","z":"949196be916a8bda","name":"get days left","func":"// Assuming date1 and date2 are in the format \"YYYY-MM-DD\"\nlet date1 = msg.time;\nlet date2 = msg.payload.due;\n\nlet d1 = new Date(date1);\nlet d2 = new Date(date2);\n\n// Get the difference in milliseconds\nlet differenceInMs = d2.getTime() - d1.getTime();\n\n// Convert the difference from milliseconds to days\nlet differenceInDays = differenceInMs / (1000 * 60 * 60 * 24);\n\nmsg.days_remaining = differenceInDays;\n\nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":630,"y":800,"wires":[["bf53943f58171914"]]},{"id":"bf53943f58171914","type":"switch","z":"949196be916a8bda","name":"<2","property":"days_remaining","propertyType":"msg","rules":[{"t":"lt","v":"2","vt":"num"}],"checkall":"true","repair":false,"outputs":1,"x":770,"y":800,"wires":[["d5100e1fe26838df"]]},{"id":"d5100e1fe26838df","type":"api-call-service","z":"949196be916a8bda","name":"assign due date","server":"c4920a33.918dc8","version":5,"debugenabled":false,"domain":"todo","service":"update_item","areaId":[],"deviceId":[],"entityId":[],"data":"{\"item\":\"{{payload.summary}}\",\"status\":\"needs_action\",\"entity_id\":\"{{list}}\"}","dataType":"json","mergeContext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":920,"y":800,"wires":[["50d3830d24d83e34"]]},{"id":"34e4f2cb551941c8","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::weekly","pt":"flow","to":"payload.response[\"todo.weekly\"].items","tot":"msg"},{"t":"set","p":"#:(store)::fortnightly","pt":"flow","to":"payload.response[\"todo.fortnightly\"].items","tot":"msg"},{"t":"set","p":"#:(store)::monthly","pt":"flow","to":"payload.response[\"todo.monthly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1190,"y":800,"wires":[[]]},{"id":"50d3830d24d83e34","type":"ha-api","z":"949196be916a8bda","name":"","server":"c4920a33.918dc8","version":1,"debugenabled":false,"protocol":"websocket","method":"get","path":"","data":"{\t \"type\": \"execute_script\",\t \"sequence\": [\t {\t \"service\" : \"todo.get_items\",\t \"target\" : {\t \"entity_id\" : [\"todo.weekly\", \"todo.fortnightly\", \"todo.monthly\"]\t },\t \"data\" : {\t \"status\": [\"needs_action\", \"completed\"]\t },\t \"response_variable\" : \"service_result\"\t },\t {\t \"stop\" : \"done\",\t \"response_variable\": \"service_result\"\t }\t ]\t}","dataType":"jsonata","responseType":"json","outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"results"}],"x":1070,"y":800,"wires":[["34e4f2cb551941c8"]]},{"id":"9bc6dc3a0af429e4","type":"trigger-state","z":"949196be916a8bda","name":"change","server":"c4920a33.918dc8","version":4,"inputs":0,"outputs":2,"exposeAsEntityConfig":"","entityId":"todo.fortnightly","entityIdType":"exact","debugEnabled":false,"constraints":[],"customOutputs":[],"outputInitially":false,"stateType":"str","enableInput":false,"x":70,"y":380,"wires":[["3fa9ac8cd2ab773e"],[]]},{"id":"cfa0c7e4a10d21a1","type":"api-call-service","z":"949196be916a8bda","name":"assign due date","server":"c4920a33.918dc8","version":5,"debugenabled":false,"domain":"todo","service":"update_item","areaId":[],"deviceId":[],"entityId":[],"data":"{\"item\":\"{{payload.new_state.summary}}\",\"due_date\":\"{{due}}\",\"entity_id\":\"todo.fortnightly\"}","dataType":"json","mergeContext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":1540,"y":380,"wires":[["d167835f64264ee1"]]},{"id":"684214a8ba5c7277","type":"moment","z":"949196be916a8bda","name":"get due date","topic":"","input":"","inputType":"date","inTz":"Europe/London","adjAmount":"14","adjType":"days","adjDir":"add","format":"YYYY-MM-DD","locale":"C","output":"due","outputType":"msg","outTz":"Europe/London","x":1370,"y":380,"wires":[["cfa0c7e4a10d21a1"]]},{"id":"687a5f2a13dc766a","type":"switch","z":"949196be916a8bda","name":"saved data?","property":"#:(store)::fortnightly","propertyType":"flow","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":330,"y":380,"wires":[["230c2d8ff1975764"],["0ba21c1754e1bf77"]]},{"id":"230c2d8ff1975764","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::fortnightly","pt":"flow","to":"payload.response[\"todo.fortnightly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":490,"y":340,"wires":[[]]},{"id":"3fa9ac8cd2ab773e","type":"ha-api","z":"949196be916a8bda","name":"","server":"c4920a33.918dc8","version":1,"debugenabled":false,"protocol":"websocket","method":"get","path":"","data":"{\t \"type\": \"execute_script\",\t \"sequence\": [\t {\t \"service\" : \"todo.get_items\",\t \"target\" : {\t \"entity_id\" : \"todo.fortnightly\"\t },\t \"data\" : {\t \"status\": [\"needs_action\", \"completed\"]\t },\t \"response_variable\" : \"service_result\"\t },\t {\t \"stop\" : \"done\",\t \"response_variable\": \"service_result\"\t }\t ]\t}","dataType":"jsonata","responseType":"json","outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"results"}],"x":190,"y":380,"wires":[["687a5f2a13dc766a"]]},{"id":"0ba21c1754e1bf77","type":"change","z":"949196be916a8bda","name":"load saved","rules":[{"t":"set","p":"fortnightly","pt":"msg","to":"#:(store)::fortnightly","tot":"flow"}],"action":"","property":"","from":"","to":"","reg":false,"x":510,"y":380,"wires":[["139dc8643de660c4"]]},{"id":"139dc8643de660c4","type":"function","z":"949196be916a8bda","name":"get changes","func":"function compareArrays(newArray, oldArray) {\n let changes = [];\n\n newArray.forEach(newItem => {\n let oldItem = oldArray.find(item => item.uid === newItem.uid);\n if (!oldItem) {\n changes.push({\n old_state: null,\n new_state: newItem\n });\n } else if (JSON.stringify(oldItem) !== JSON.stringify(newItem)) {\n changes.push({\n old_state: oldItem,\n new_state: newItem\n });\n }\n });\n\n return changes;\n}\n\nlet newArray = msg.payload.response[\"todo.fortnightly\"].items;\nlet oldArray = msg.fortnightly;\n\nmsg.changes = compareArrays(newArray, oldArray);\n\nreturn msg;\n","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":670,"y":380,"wires":[["25407011be4ec400","892fb8b0223ed26e"]]},{"id":"142fc9b9e5d5fc41","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::fortnightly","pt":"flow","to":"payload.response[\"todo.fortnightly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1810,"y":380,"wires":[[]]},{"id":"2822a0f720a088eb","type":"switch","z":"949196be916a8bda","name":"new item?","property":"payload.old_state","propertyType":"msg","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1010,"y":380,"wires":[["8b3a545654b210fe"],["f972f778e8d287ac"]]},{"id":"d167835f64264ee1","type":"ha-api","z":"949196be916a8bda","name":"","server":"c4920a33.918dc8","version":1,"debugenabled":false,"protocol":"websocket","method":"get","path":"","data":"{\t \"type\": \"execute_script\",\t \"sequence\": [\t {\t \"service\" : \"todo.get_items\",\t \"target\" : {\t \"entity_id\" : \"todo.fortnightly\"\t },\t \"data\" : {\t \"status\": [\"needs_action\", \"completed\"]\t },\t \"response_variable\" : \"service_result\"\t },\t {\t \"stop\" : \"done\",\t \"response_variable\": \"service_result\"\t }\t ]\t}","dataType":"jsonata","responseType":"json","outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"results"}],"x":1690,"y":380,"wires":[["142fc9b9e5d5fc41"]]},{"id":"f972f778e8d287ac","type":"switch","z":"949196be916a8bda","name":"changed status?","property":"payload.new_state.status","propertyType":"msg","rules":[{"t":"neq","v":"payload.old_state.status","vt":"msg"}],"checkall":"true","repair":false,"outputs":1,"x":1030,"y":440,"wires":[["47a4aa73a4c26221"]]},{"id":"47a4aa73a4c26221","type":"switch","z":"949196be916a8bda","name":"new status?","property":"payload.new_state.status","propertyType":"msg","rules":[{"t":"eq","v":"completed","vt":"str"},{"t":"eq","v":"needs_action","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":1210,"y":440,"wires":[["684214a8ba5c7277"],[]]},{"id":"892fb8b0223ed26e","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::fortnightly","pt":"flow","to":"payload.response[\"todo.fortnightly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":810,"y":340,"wires":[[]]},{"id":"25407011be4ec400","type":"function","z":"949196be916a8bda","name":"split and send","func":"for (var i = 0; i < msg.changes.length; i++) {\n var newMsg = {};\n newMsg.payload = msg.changes[i];\n node.send(newMsg);\n}\nreturn null;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":840,"y":380,"wires":[["2822a0f720a088eb"]]},{"id":"8b3a545654b210fe","type":"switch","z":"949196be916a8bda","name":"has date?","property":"payload.new_state.due","propertyType":"msg","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1200,"y":380,"wires":[["684214a8ba5c7277"],[]]},{"id":"58ea7c9a2490a150","type":"trigger-state","z":"949196be916a8bda","name":"change","server":"c4920a33.918dc8","version":4,"inputs":0,"outputs":2,"exposeAsEntityConfig":"","entityId":"todo.monthly","entityIdType":"exact","debugEnabled":false,"constraints":[],"customOutputs":[],"outputInitially":false,"stateType":"str","enableInput":false,"x":70,"y":560,"wires":[["f4e3efa850272fd4"],[]]},{"id":"bbad9da5a9e9e70d","type":"api-call-service","z":"949196be916a8bda","name":"assign due date","server":"c4920a33.918dc8","version":5,"debugenabled":false,"domain":"todo","service":"update_item","areaId":[],"deviceId":[],"entityId":[],"data":"{\"item\":\"{{payload.new_state.summary}}\",\"due_date\":\"{{due}}\",\"entity_id\":\"todo.monthly\"}","dataType":"json","mergeContext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":1540,"y":560,"wires":[["9ec56908da9a3c50"]]},{"id":"be1116acd25b0a3b","type":"moment","z":"949196be916a8bda","name":"get due date","topic":"","input":"","inputType":"date","inTz":"Europe/London","adjAmount":"28","adjType":"days","adjDir":"add","format":"YYYY-MM-DD","locale":"C","output":"due","outputType":"msg","outTz":"Europe/London","x":1370,"y":560,"wires":[["bbad9da5a9e9e70d"]]},{"id":"4fae201ec764c9b3","type":"switch","z":"949196be916a8bda","name":"saved data?","property":"#:(store)::monthly","propertyType":"flow","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":330,"y":560,"wires":[["204bd3d0570999a5"],["812965e2ebf9f24a"]]},{"id":"204bd3d0570999a5","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::monthly","pt":"flow","to":"payload.response[\"todo.monthly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":490,"y":520,"wires":[[]]},{"id":"f4e3efa850272fd4","type":"ha-api","z":"949196be916a8bda","name":"","server":"c4920a33.918dc8","version":1,"debugenabled":false,"protocol":"websocket","method":"get","path":"","data":"{\t \"type\": \"execute_script\",\t \"sequence\": [\t {\t \"service\" : \"todo.get_items\",\t \"target\" : {\t \"entity_id\" : \"todo.monthly\"\t },\t \"data\" : {\t \"status\": [\"needs_action\", \"completed\"]\t },\t \"response_variable\" : \"service_result\"\t },\t {\t \"stop\" : \"done\",\t \"response_variable\": \"service_result\"\t }\t ]\t}","dataType":"jsonata","responseType":"json","outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"results"}],"x":190,"y":560,"wires":[["4fae201ec764c9b3"]]},{"id":"812965e2ebf9f24a","type":"change","z":"949196be916a8bda","name":"load saved","rules":[{"t":"set","p":"monthly","pt":"msg","to":"#:(store)::monthly","tot":"flow"}],"action":"","property":"","from":"","to":"","reg":false,"x":510,"y":560,"wires":[["1fe8429b9e714168"]]},{"id":"1fe8429b9e714168","type":"function","z":"949196be916a8bda","name":"get changes","func":"function compareArrays(newArray, oldArray) {\n let changes = [];\n\n newArray.forEach(newItem => {\n let oldItem = oldArray.find(item => item.uid === newItem.uid);\n if (!oldItem) {\n changes.push({\n old_state: null,\n new_state: newItem\n });\n } else if (JSON.stringify(oldItem) !== JSON.stringify(newItem)) {\n changes.push({\n old_state: oldItem,\n new_state: newItem\n });\n }\n });\n\n return changes;\n}\n\nlet newArray = msg.payload.response[\"todo.monthly\"].items;\nlet oldArray = msg.monthly;\n\nmsg.changes = compareArrays(newArray, oldArray);\n\nreturn msg;\n","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":670,"y":560,"wires":[["8d05c53cd765e2db","e0c093aaf5a1409c"]]},{"id":"a028ad6e7d59df27","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::monthly","pt":"flow","to":"payload.response[\"todo.monthly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1810,"y":560,"wires":[[]]},{"id":"f56417cd1eaf274c","type":"switch","z":"949196be916a8bda","name":"new item?","property":"payload.old_state","propertyType":"msg","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1010,"y":560,"wires":[["2008a9873cfd3f28"],["def35e8808b5960b"]]},{"id":"9ec56908da9a3c50","type":"ha-api","z":"949196be916a8bda","name":"","server":"c4920a33.918dc8","version":1,"debugenabled":false,"protocol":"websocket","method":"get","path":"","data":"{\t \"type\": \"execute_script\",\t \"sequence\": [\t {\t \"service\" : \"todo.get_items\",\t \"target\" : {\t \"entity_id\" : \"todo.monthly\"\t },\t \"data\" : {\t \"status\": [\"needs_action\", \"completed\"]\t },\t \"response_variable\" : \"service_result\"\t },\t {\t \"stop\" : \"done\",\t \"response_variable\": \"service_result\"\t }\t ]\t}","dataType":"jsonata","responseType":"json","outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"results"}],"x":1690,"y":560,"wires":[["a028ad6e7d59df27"]]},{"id":"def35e8808b5960b","type":"switch","z":"949196be916a8bda","name":"changed status?","property":"payload.new_state.status","propertyType":"msg","rules":[{"t":"neq","v":"payload.old_state.status","vt":"msg"}],"checkall":"true","repair":false,"outputs":1,"x":1030,"y":620,"wires":[["d8f8755094d84e90"]]},{"id":"d8f8755094d84e90","type":"switch","z":"949196be916a8bda","name":"new status?","property":"payload.new_state.status","propertyType":"msg","rules":[{"t":"eq","v":"completed","vt":"str"},{"t":"eq","v":"needs_action","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":1210,"y":620,"wires":[["be1116acd25b0a3b"],[]]},{"id":"e0c093aaf5a1409c","type":"change","z":"949196be916a8bda","name":"save","rules":[{"t":"set","p":"#:(store)::monthly","pt":"flow","to":"payload.response[\"todo.monthly\"].items","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":810,"y":520,"wires":[[]]},{"id":"8d05c53cd765e2db","type":"function","z":"949196be916a8bda","name":"split and send","func":"for (var i = 0; i < msg.changes.length; i++) {\n var newMsg = {};\n newMsg.payload = msg.changes[i];\n node.send(newMsg);\n}\nreturn null;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":840,"y":560,"wires":[["f56417cd1eaf274c"]]},{"id":"2008a9873cfd3f28","type":"switch","z":"949196be916a8bda","name":"has date?","property":"payload.new_state.due","propertyType":"msg","rules":[{"t":"null"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":1200,"y":560,"wires":[["be1116acd25b0a3b"],[]]},{"id":"885f39cbe3d99b7f","type":"comment","z":"949196be916a8bda","name":"weekly","info":"","x":70,"y":160,"wires":[]},{"id":"8b4f1201705c9669","type":"comment","z":"949196be916a8bda","name":"fortnightly","info":"","x":80,"y":340,"wires":[]},{"id":"521f1ec42832df3e","type":"comment","z":"949196be916a8bda","name":"monthly","info":"","x":70,"y":520,"wires":[]},{"id":"5361f89104825bce","type":"comment","z":"949196be916a8bda","name":"repopulate when due","info":"","x":120,"y":760,"wires":[]},{"id":"c4920a33.918dc8","type":"server","name":"Home Assistant","version":5,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true,"heartbeat":false,"heartbeatInterval":30,"areaSelector":"friendlyName","deviceSelector":"friendlyName","entitySelector":"friendlyName","statusSeparator":"at: ","statusYear":"hidden","statusMonth":"short","statusDay":"numeric","statusHourCycle":"h23","statusTimeFormat":"h:m","enableGlobalContextStore":true}]

EDIT: Apologies if this isn't related to the issue above - I can make a new issue if so - and sorry for the giant wall of nodered!

@Shredder5262
Copy link

I think i might be experiencing this as well. I see several todo lists as entities, but I do not see them in the todo list section and if i were to add the todo list entities as cards they are blacked out. How do i restore the lists?

@allenporter
Copy link
Contributor

allenporter commented Mar 14, 2024

Last two of you: please upgrade to 2024.3.1 which fixes those issues.

@ludditus-RPI
Copy link

ludditus-RPI commented Mar 14, 2024

Same error, with additional complication after upgrading to 2024.3.1, and a succesful (but manual) resolution. Here's what I observed:

  • I had the original "missing timezone" error when trying to add a date to a list item, with a list from the Local To-do integration (using v2024.3.0)
  • I upgraded to 2024.3.1
  • The list where I experienced the original error was now missing from the To-do section of the UI. Clicking on the entity showed "This entity is no longer being provided by the local_todo integration". I attempted to reenable/restore the entity, reload the integration, none of that worked.

The affected list entity was "homelab". I could no longer see the items on there, either through the UI or manually editing the URL to https://localURL/todo?entity_id=todo.homelab.

I was able to see the data file in /homeassistant/.storage/local_todo.homelab.ics, with the original entries. The entry which was previously causing the timezone error was:

BEGIN:VTODO
DTSTAMP:20240314T152631
UID:3bec2ae6-e217-11ee-95ff-dca632657d7d
CREATED:20240314T152631
DTSTART;TZID=EDT:20240314T112631
SEQUENCE:0
STATUS:NEEDS-ACTION
SUMMARY:<description of the item>
END:VTODO
  • I manually deleted the DTSTART line from the file editor menu, saved, reloaded the integration and the 'homelab' list was restored to the UI. I was then able to update the affected entry by adding a date, and the TZ error did not recur. After doing that, the entry now reads:
BEGIN:VTODO
DTSTAMP:20240314T191320
UID:3bec2ae6-e217-11ee-95ff-dca632657d7d
CREATED:20240314T152631
DESCRIPTION:<description text>
DUE:20250411
LAST-MODIFIED:20240314T191320
SEQUENCE:1
STATUS:NEEDS-ACTION
SUMMARY:<summary text>
END:VTODO

Hope this helps in troubleshooting, or for others with orphaned/missing to-do lists after the 2024.3.1 upgrade.

@aegjoyce
Copy link

Last two of you: please upgrade to 2024.3.1 which fixes those issues.

My issue - fixed by 2024.3.1. Many thanks

@Blackshome
Copy link

Blackshome commented Mar 15, 2024

Hi @allenporter

I have updated to 2024.3.1 but my to-do list are still inactive. Do you need any more information from me? Thanks for your help.

Error while setting up local_todo platform for todo
Traceback (most recent call last):
File "/usr/local/lib/python3.12/site-packages/ical/component.py", line 139, in init
super().init(**data)
File "/usr/local/lib/python3.12/site-packages/pydantic/main.py", line 341, in init
raise validation_error
pydantic.error_wrappers.ValidationError: 1 validation error for Todo
root
Failed to validate: 20240311T214041, errors: (["Expected DATE-TIME TZID value 'AEDT' to be valid timezone", "Expected value to match DATE pattern: '20240311T214041'"]) (type=value_error)

The above exception was the direct cause of the following exception:

28
27
26
25

@allenporter
Copy link
Contributor

@Blackshome thanks for the report, we have issues tracking the additional set of issues that were not resolved in 2024.3.1 e.g. #113445

@Blackshome
Copy link

@allenporter thanks for the info Allen, looks like you all over it. We will wait for the patch from you. Again thanks for your help and everything you do for HA.

@github-actions github-actions bot locked and limited conversation to collaborators Apr 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet