ICS Calendar platform

Nobody has an idea?

My ICS platform doesn’t create any sensors, only a calendar, so I have no idea how you created the sensors or how you want to display them, so I’m not sure I can be of any help.

In general, though, the “sensor” card is a good place to start for displaying sensors.

sorry my mistake…

2 questions:

Can i use a local ics file like this:

calendar:
- platform: ics
  calendars:
      - name: Familie
        url: /local/kalender.ics

Can i use a Apple icloud Calendar:

calendar:
- platform: ics
  calendars:
      - name: Familie
        url: https://p14-caldav.icloud.com/.....

The local file might work, particularly if you specify file:///local/kalendar.ics. I haven’t tested that, but if it doesn’t work, please open an issue on Github (https://github.com/franc6/ics_calendar), and I’ll fix it.

For iCloud, please use the built-in caldav calendar platform. iCloud uses CalDAV, so that’s more appropriate. I’d be very surprised if my stuff works with iCloud – it’s not intended to handle proper CalDAV authentication. Also, since the URL that my stuff would use is both different from what the proper CalDAV URL and is something that could change without notice, even if it does work now, it would be very fragile.

1 Like

I’ve used a local file, put into the /config/www directory and then use https://yourexternalurl/local/file.ics

1 Like

hi,

this one works for a local file:

calendar:
- platform: ics
  calendars:
      - name: Müllabfuhr
        url: http://localhost:8123/local/kalender.ics
        includeAllDay: true

Thank you!!

Anyone got this working with Google Calendar? It showed up some events briefly, but doesn’t really seem to work. Also, will it update the events in realtime, or do you need to restart HA every time or use a service call?

I know there is a Google Calendar integration, but I want to use iCal instead. Google Calendar has issues lately and needs to be reauthenticated too much for my taste.

It depends. If it’s a public calendar, that’s my own main use case. I didn’t want to log in to be able to use a public Google calendar.

f the calendar isn’t public, I would not expect it to work.

It will update as regularly as Home Assistant requests updates, up to once every 15 minutes (at least I think I got that limitation working). So don’t expect updates immediately after changing the calendar, but you don’t need to restart HA.

Oh, and the new calendar controls on HA are awful, frequently removing everything and taking several minutes to display. If events disappear every time you switch from the view showing you the calendar, that’s probably the problem. Most calendar displays for HA are similar but some were not as slow to update their display. Unfortunately, the best have since gone away. :frowning:

Thank you for responding! Yes the calendar integration of HA is terrible. That works crappy with Google now as well, it misses events that the calendar card I use (atom revive) does show thankfully. I tried using the secret link of my Google iCal url. Google states that anyone with the link can view it (which indeed works when I open the ics file with on my PC). This should work right?

The calendar however also didn’t show any events with this iCS platform. I also noticed my system suddenly hanging a lot (for minutes on end and then every few seconds it repeated that). Could be something else, but a restart of HA didn’t fix it. Then I deleted the integration and HA has been working as before. Could be totally unrelated ofcourse.

I’ll try again, perhaps I was having other issues.

If you try again, please try the BETA version. If you’re installing through HACS, you have to tell it to show you BETA versions where you configure the repository. Otherwise, it should show up in the Releases page.

Additionally, what kind of hardware are you running on? I’ve heard reports (see above) of unacceptably slow performance on small systems, like Raspberry pis – the behavior you mention sounds very much the same, and I think the BETA version is better (although not good enough, IMO). I should have thought of this problem sooner, but it’s not one I personally experience. :frowning:

And yes, using that URL should work just fine.

1 Like

I’ll try the beta. I got it working btw with the secret url’s, but indeed system was very unstable again so ended up removing again. I’m running on RPI4. Hopefully the beta runs better. This is an amazing component (which should be a core feature imho) so I hope it becomes stable at some point :slight_smile:

I just realized I forgot to reply. :frowning: Thanks for the info. I think I’m gonna have to get an rPi that is capable of running HA to do some performance testing on it. I’ve had some other ideas, too.

As for being a core feature, I gotta disagree. I think it’s great that HA is providing a calendar feature and even a UI for it. But specific implementations ought to be left for third-parties. It helps keep installations smaller and lets people like me learn far more about HA than I would otherwise. :wink:

1 Like

If your amazing component will work then I totally agree with you. Let me know if you need someone testing. I removed the component because it caused too much freezing, but I can always test for a few hours when nobody’s home :)!

hi, the url dont work with !secret ? :thinking:

- platform: ics
  name: Restmülltonne
  url: !secret ics_url

After use the secret, many error is in the log-file :frowning:

Thanks

There’s no code to specifically enable the use of !secret. I haven’t looked into this yet, but my guess would be that whatever processes !secret in HA doesn’t do it for urls. If the errors are directly related to the URL, I would expect you’d see the message:

Restmülltonne: Failed to open url: !secret ics_url

If you don’t see that error message, then send me the errors privately, please, as it’s likely to be something else wrong.

here the issue:

(This is my first post😯)
Im very interrestet to get famelywall in HA.
BUT im rooki… i cant figure the code you have postet, can you please specify for me?

Newbie here…

I’m trying to add my outlook calendar but i’m running itno following error in log:

Failed to open url: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1123)

What am i doing wrong?

@rafterk You might be doing nothing wrong. In order to establish a TLS connection, you need your server to use trusted certificates. That error message usually means that a self-signed certificate was used. For most setups, there’s nothing you (as an end-user) need to do, but whoever owns the server has to do more. :slight_smile:

If you are running the server, or know who does and trust that person, you might be able to work around this problem, depending on how you’ve installed Home Assistant.

If you are running a supervised installation, you need to work on getting the server to use a trusted root. The cheapest way to do that is through Let’s Encrypt. There’s a lot of information available on the 'net to explain that depending on the exact setup. I probably can’t help.

If you aren’t running a supervised installation, then you need to add the server’s certificate (or its root certificate) to your trusted root store. I can’t really explain how to do that on this forum, and I don’t know enough about your system to be certain that I know how to do it, anyway. :slight_smile: In theory, you could do this for a supervised install of Home Assistant, but in practice, I don’t think it’s worth the trouble, especially since I’m pretty sure that any “fix” would disappear the next time you update Home Assistant.

I hope this helps you start on determining what you need to do to work around the problem.

Hello, thanks for the great custom component. No problem in installing and configuring it. Although I have a problem related to time zones with outlook.com.

I have an example in outlook.com:

using calendar share options, and export to ICS.
When this is imported in HA, I get the following for this specific event:
image

although my time zone settings are correct in HA:

I checked the ICS file: time is okay, timezone also.

Anyone some idea?
Thanks in advance :yum:
Frederik.