home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
69.03k stars 28.28k forks source link

local_todo can't add new item #116761

Open mesut3000 opened 2 weeks ago

mesut3000 commented 2 weeks ago

The problem

When I try to add new item, I have this error message :

Failed to call service todo/add_item. TodoStore.init() got an unexpected keyword argument 'tzinfo'

What version of Home Assistant Core has the issue?

core-2024.5.0

What was the last working version of Home Assistant Core?

core-2024.4.0

What type of installation are you running?

Home Assistant OS

Integration causing the issue

local_todo

Link to integration documentation on our website

No response

Diagnostics information

546233124928] Unexpected 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 2738, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2779, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 975, in entity_service_call
    single_response = await _handle_entity_call(
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1047, in _handle_entity_call
    result = await task
             ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/todo/__init__.py", line 463, in _async_add_todo_item
    await entity.async_create_todo_item(
  File "/usr/src/homeassistant/homeassistant/components/local_todo/todo.py", line 162, in async_create_todo_item
    self._new_todo_store().add(todo)
    ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/local_todo/todo.py", line 137, in _new_todo_store
    return TodoStore(self._calendar, tzinfo=dt_util.DEFAULT_TIME_ZONE)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: TodoStore.__init__() got an unexpected keyword argument 'tzinfo'

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

home-assistant[bot] commented 1 week ago

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)

allenporter commented 1 week ago

@mesut3000 i'm assuming you have custom components installed that are installing another version of ical that break home assistant?

In the template under "Diagnostics information" its asking for this https://www.home-assistant.io/docs/configuration/troubleshooting/#download-diagnostics so if you attach that it will show what custom components you have installed. Or you can try in safe mode and see if that helps?

mesut3000 commented 1 week ago

I only see todoist-task-list / TodoIst Home Assistant lovelace card in HACS and removed it but it didn't change. Then I reboot system and it is working now, strange.

allenporter commented 1 week ago

Ok, something was holding it back to an old python package version but perhaps it was able to resolve on restart