简体   繁体   English

Python icalendar无法识别密钥

[英]Python icalendar not recognising key


Hi There, 嗨,您好,

I'm new to parsing iCal and was wondering why I am getting the following error. 我是解析iCal的新手,想知道为什么我遇到以下错误。

I have the following iCal format and I'm using the icalendar library for python to parse it. 我具有以下iCal格式,并且正在使用icalendar库进行python解析。 Unfortunately the ATTENDEE key is not being recognised and will only be recognised when placing a tab beside the new line. 不幸的是,ATTENDEE键无法识别,只有在新行旁边放置一个选项卡时才能识别。 How come this is the case? 怎么会这样呢? The iCal validator claims this is valid iCal iCal验证程序声称这是有效的iCal

 BEGIN:VCALENDAR
 PRODID:-// Example classroom timetable
 VERSION:2.0
 BEGIN:VEVENT
 ATTENDEE;CN=91827364;ROLE=REQ-PARTICIPANT;PARTSTAT=ACCEPTED;DELEGATED-FROM
 ="mailto:teststudent@class.com":mailto:teststudent@class.com
 ATTENDEE;CN=81726354;ROLE=REQ-PARTICIPANT;PARTSTAT=ACCEPTED;DELEGATED-FROM 
 ="mailto:teststudent2@class.com":mailto:teststudent2@class.com
 ATTENDEE;CN=31602424;ROLE=REQ-PARTICIPANT;PARTSTAT=ACCEPTED;DELEGATED-FROM
 ="mailto:teststudent3@class.com":mailto:teststudent3@class.com
 ATTENDEE;CN=40049549;ROLE=REQ-PARTICIPANT;PARTSTAT=ACCEPTED;DELEGATED-FROM
 ="mailto:teststudent4@class.com":mailto:teststudent4@class.com
 CREATED:20180730T220042Z
 DESCRIPTION:MA1234 - MATHEMATIC\n\n Event Type:LECTURE\n\n 
   Lecturer(s):DR.1\n\n Location(s):CLASSROOM 3
 DTEND:20170926T170000Z
 DTSTAMP:20180730T220042Z
 DTSTART:20170926T160000Z
 LAST-MODIFIED:20170601T105200Z
 LOCATION:CLASSROOM3
 SEQUENCE:0
 SUMMARY:MA1234 - MATHEMATICS
 UID:0000924617001-1726920-XXXXXXXXXX@class.com
 END:VEVENT
 END:VCALENDAR

Thanks for your help! 谢谢你的帮助!

Lines longer than 75 characters must be folded in a specific way.. CRLF immediately followed by a single linear white-space character (ie, SPACE or HTAB) 超过75个字符的行必须以特定的方式折叠。CRLF后面紧跟一个线性空格字符(即SPACE或HTAB)

https://tools.ietf.org/html/rfc5545#section-3.1 https://tools.ietf.org/html/rfc5545#section-3.1

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM