[Pycon-interest] Schedule now available in iCal format
goodger at python.org
Wed Feb 1 23:02:15 CET 2006
I took a look at the code and compared an iCal-generated .ics file
with the PyCon schedule.ics. I think the problem has to do with this
print >>output, 'UID:%s@%s' % (date, 'pycon.org')
print >>output, 'SEQUENCE:1'
# XXX what are these two?
print >>output, 'DTSTAMP:%s' % date
print >>output, 'DURATION:PT%iM' % duration
I assume that the strangely-positioned comment refers to the two lines
*above* it, because the two below are OK. RFC 2445 gave me some
4.6.4 Free/Busy Component
"UID" and "DTSTAMP" properties are specified to assist in proper
sequencing of multiple free/busy time replies.
188.8.131.52 Unique Identifier
Property Name: UID
Purpose: This property defines the persistent, globally unique
identifier for the calendar component.
184.108.40.206 Date/Time Stamp
Property Name: DTSTAMP
Purpose: The property indicates the date/time that the instance of
the iCalendar object was created.
Description: The value MUST be specified in the UTC time format.
Also, the RFC's grammar specifies CRLF line endings, so I added a
wrapper for sys.stdout (is there an easier way, idiom, or "one true
way" to do this?).
So I've fixed up parse_sched.py to produce unique IDs (UID values),
based on a combination of date, time, & room of the event, which must
be unique. Also removed extra spaces after "LOCATION:" and "SUMMARY:"
labels. Now in iCal 1.5.5 the calendar looks *much* better.
Check-in in 5 minutes.
David Goodger <http://python.net/~goodger>
More information about the Pycon-interest