Skip Menu |

This queue is for tickets about the Data-ICal CPAN distribution.

Report information
The Basics
Id: 65447
Status: resolved
Priority: 0/
Queue: Data-ICal

People
Owner: Nobody in particular
Requestors: jordi.amo [...] gmail.com
njh [...] bandsman.co.uk
Cc: alexm [...] cpan.org
AdminCc:

Bug Information
Severity: Important
Broken in: 0.18
Fixed in: (no value)



Subject: prodid and version parameters order
Date: Fri, 4 Feb 2011 11:50:15 +0100
To: bug-Data-ICal [...] rt.cpan.org
From: Jordi Amorós <jordi.amo [...] gmail.com>
Dear mantainers, I've 'discovered'* that the files generated with Data::ICal have an issue: the order of prodid and version parameters is not correct. "BEGIN:VCALENDAR PRODID:-//Smeagol Server //VERSION 2.x//EN VERSION:2.0 ... " should be: "BEGIN:VCALENDAR VERSION:2.0 PRODID:-//Smeagol Server //VERSION 2.x//EN ... " If you fix that, then the .ics files generated will become perfect. Thanks for your great job! :D *ESL, I'm not sure if discover is the appropriate word to use here.
Subject: [rt.cpan.org #65447] Additional information
Date: Fri, 4 Feb 2011 12:12:50 +0100
To: bug-Data-ICal [...] rt.cpan.org
From: Jordi Amorós <jordi.amo [...] gmail.com>
Data::ICal version, copied and pasted from /usr/share/perl5/Data/ICal.pm: $VERSION = '0.16'; $perl -v This is perl, v5.10.1 (*) built for i686-linux-gnu-thread-multi .......@m83:~$ uname -a Linux m83 2.6.35-25-generic #44-Ubuntu SMP Fri Jan 21 17:40:48 UTC 2011 i686 GNU/Linux
Subject: VERSION is not put first
According to http://icalvalid.cloudapp.net/Default.aspx, "The VERSION property should be the first property on the calendar. Some calendar clients cannot properly parse the calendar otherwise." However, with Data::Ical, VERSION doesn't appear first: BEGIN:VCALENDAR CALSCALE:GREGORIAN METHOD:PUBLISH PRODID:Data::ICal 0.16 VERSION:2.0 ...
An ugly quickfix could be replacing line 107 in ICal/Entry.pm with the following: # RFC2445 implies an order (see 4.6 Calendar Components) but does not require it, # however some applications break if VERSION is not first, see # http://icalvalid.cloudapp.net/Default.aspx for my $name ( sort { if ($a eq 'version') { return -1 }; if ($b eq 'version') { return 1 }; } keys %{ $self->properties } ) {
Fixed in 0.19, just pushed to CPAN now. Thanks for the report and suggested patch! https://metacpan.org/release/TSIBLEY/Data-ICal-0.19