I’ve recently setup google calendar and am having an issue getting the location, start and end time to show up in my group from the sensor. Here is what shows currently and my code. Am I doing the sensor attributes correctly? I wish there was some more info in the Google Calendar doc on HA.
You need template sensors for the other attributes. Just like you did with ‘message’, create sensors for the other attributes. I don’t have location set up, but here’s how I get the start, end and all day attributes:
@thechriswick would you mind sharing all your config for the google calendar setup? I have only made the first configuration and got the google_calendars.yaml file. Im to new with home assistant so i would like to see an example to get up and running like you did.
Sorry im such a newbie but have been tinkering around alot lately and starting to get a hang of how this works
so in general to get this to work you do:
in google_calendars.yaml you take the calndars device_id and replace DEVICE_ID with yours {{ states.calendar.DEVICE_ID.attributes.message }}
This will create a new top meny called Hem and inside that a box called Kalender will show you all info for the calender choosen.
I get one error though when starting up home assistant:
homeassistant.components.sensor.template: UndefinedError: ‘None’ has no attribute ‘attributes’
but it works…
When making a sensor for a calendar that i subscribe to i get this error in the log file wonder what that is. the built in google calendar component that shows all calendars works.
homeassistant.components.sensor.template: SecurityError: access to attribute '_7a__1617' of 'DomainStates' object is unsafe.
It could be that the value of the End Time is a string instead of an integer and the template is looking for an integer or vice versa. Again, just a guess.
@Coolie1101 - I was curious about this as most of my descriptions are short so I edited one that was upcoming to see what happened and mine is wrapping fine:
But I’m not doing anything special with the template sensors or group so I’m not sure why yours isn’t wrapping properly.
I’m curious about something off topic… Do you see more than one event? I setup this component but I only see the next upcoming event and nothing else do you have this same behaviour?