Labels in todo list (and CalDav backend)

Hi!

I am using nextcloud to manage my todos and would like to do automations based on them in home assistant. I am using the CalDav integration which works just fine.

However, it does not support caldav labels which I am using quite heavily. Moreover, I noticed the todo integration also does not support giving the tasks labels.

In my opnion it would make sense to add support for those labels in both integrations as this would not only greatly benefit caldav integration users but also everyone using the todo functionality.

Note: This idea was also briefly mentioned in To-do list card customisation and filtering, but only for the todo integration and not the caldav integration and only with focus on the to do list card.

This might need consideration with how it is implemented now that home assistant has the concept of “labels” which are applicable across entity types. This also applies to the linked feature request.

For example:

  • Should todo item labels use the same label system as the rest of home assistant?
  • If not, what should they be called to avoid confusion?
  • If they are the same, what should happen if a “remote” label doesn’t exist locally? Is it created automatically, ignored, or something else?
  • Should labels in home assistant be created on the remote as well? When should this happen? Only when they are used?

In general though I’m in favour of todo item labels. I think many providers have the concept of an item label so it would be good to implement in a generic way, which can be turned on or off based on the features of the provider/integration.

There are other common item attributes which would be good to have a generic way to add as well such as priority, sections/categories, etc.