Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
After trying to deduce why my iCal feed was not being accepted by google calendar once there was a body field in place, I ran it through http://severinghaus.org/projects/icv/ to check for validation. There were a number of problems, including DSTAMP format issue, RRULE format issue, and improper formating on a long block as is often used for DESCRIPTION.
The attached patch brings my environment into full compliance with that validator. The changes all look valid when compared to the spec. I'm happy to rework it for inclusion if there are concerns on it.
Comment | File | Size | Author |
---|---|---|---|
icalfix.patch | 2.57 KB | sdague | |
Comments
Comment #1
markDrupal CreditAttribution: markDrupal commentedApplied to my local copy of calendar CVS version. Works nicely.
Thanks.
Comment #2
glen201 CreditAttribution: glen201 commentedHi, thanks for the patch.
However, the iCal still doesn't pass the validator in this post: #676264: iCal feeds not passing new validator
I get the error for each calendar entry:
However, it seems to work fine in all calendars EXCEPT for Outlook 2003 which is putting everything at GMT and definitely not picking up the time zone info.
--glen
Comment #3
markDrupal CreditAttribution: markDrupal commentedI've struggled with the same timezone issue.
It looks linux timezones (?) are not always supported. From the iCal documentation
http://www.kanzaki.com/docs/ical/dateTime.html
http://www.kanzaki.com/docs/ical/tzid.html
An example of time zones can be seen on the second page above.
Comment #4
glen201 CreditAttribution: glen201 commentedI'm not understanding the docs. Does the VTIMEZONE have to appear with each calendar entry, or just once in the ical feed?
I wouldn't mind hard-coding something (it's Drupal, after all, gotta love the path) into the module for each site, just to pass validation and maybe get Outlook 2003 to work properly with the feed.
-- glen
Comment #5
KarenS CreditAttribution: KarenS commentedThe VTIMEZONE is supposed to appear once in each feed and describes all the timezone adjustments. It is basically an RRULE for the timezone itself. It would be non-trivial to create a VTIMEZONE entry for each feed, I have no idea how to do it. And my experience is that my feeds can be imported fine into Google and elsewhere without it, so I was not planning to add it in. If someone knows a way to do it I'm open for ideas, but as far as I can tell, it would be very hard to do.
Comment #6
sdague CreditAttribution: sdague commentedThe RFC spec does require that if you use a named timezone, you specify the recurance rules, there are no such things as predefined timezones as far as the spec is concerned. Building the RRULE on the fly would sort of suck, so I've pondered building a library that would precompute those ical RRULES in advance by parsing the root tz files.
That being said, Google Calendar and Thunderbird/Lightning don't care if it's a standard timezone (like "America/New_York"), so for a lot of users this makes things much better. I couldn't add my ical into google calendar before I did these changes.
Comment #7
jakemonO CreditAttribution: jakemonO commenteddoes anyone know who maintains ical feeds for groups.drupal.org? Having a Google parsing issue...
See: http://groups.drupal.org/node/48613
Comment #8
hawleyal CreditAttribution: hawleyal commentedI'm getting newline warnings and timezone.
Comment #9
hawleyal CreditAttribution: hawleyal commentedHere's a patch to force UTC timezone for iCal feeds.
Source: Issue #757498, Comment #2
Comment #10
skwashd CreditAttribution: skwashd commentedI have been working on RFC 2445 compliance, I have submitted #760316: calendar_ical isn't RFC compliant which deals with this issue, and some others. I'd welcome any feedback.
Comment #11
stephenhendry CreditAttribution: stephenhendry commentedsubscribe
Comment #12
Herc CreditAttribution: Herc commentedRegards entry 8#
The parser is actually telling you the answer, if you read it carefully.
The DTSTAMP must be a UTC date time as per the spec. Hence you "cannot set a timezone for a UTC property"!
This is used for sequencing, so it is presumed easier if anyone is working to UTC.
UTC dates also end in with "z"
Herc
Comment #13
KarenS CreditAttribution: KarenS commentedAs near as I can tell, everything here is already addressed in #760316: calendar_ical isn't RFC compliant, so marking this a dup.