Modify ↓
Opened 18 years ago
Closed 18 years ago
#3767 closed defect (fixed)
Roadmap iCalendar not compliant with rfc2445
Reported by: | Owned by: | Christopher Lenz | |
---|---|---|---|
Priority: | normal | Milestone: | 0.10 |
Component: | roadmap | Version: | 0.10rc1 |
Severity: | normal | Keywords: | |
Cc: | Branch: | ||
Release Notes: | |||
API Changes: | |||
Internal Changes: |
Description
according to http://www.ietf.org/rfc/rfc2445.txt (at least) the following requirements are not followed by the roadmap-generated iCalendar files, causing evolution-2.8 to ignore the VTODO
items.
quoting from 4.8.4.7 Unique Identifier:
Conformance: The property MUST be specified in the "VEVENT", "VTODO", "VJOURNAL" or "VFREEBUSY" calendar components.
quoting from 4.3.11 Text:
text = *(TSAFE-CHAR / ":" / DQUOTE / ESCAPED-CHAR) ; Folded according to description above ESCAPED-CHAR = "\\" / "\;" / "\," / "\N" / "\n") ; \\ encodes \, \N or \n encodes newline ; \; encodes ;, \, encodes , TSAFE-CHAR = %x20-21 / %x23-2B / %x2D-39 / %x3C-5B %x5D-7E / NON-US-ASCII ; Any character except CTLs not needed by the current ; character set, DQUOTE, ";", ":", "\", ","
Attachments (0)
Change History (6)
comment:1 by , 18 years ago
comment:2 by , 18 years ago
Milestone: | → 0.10 |
---|---|
Version: | 0.9.5 → 0.10rc1 |
this applies to 0.10rc1 as well
comment:3 by , 18 years ago
Milestone: | 0.10 → 0.10.1 |
---|
I really think we should stop adding non-critical bug fixes to 0.10.
comment:4 by , 18 years ago
regenerated diff for RFC:2445 fix against current trunk:
-
trac/ticket/roadmap.py
209 209 else: return 'CANCELLED' 210 210 else: return '' 211 211 212 def escape_ics(text): 213 s = ''.join(map(lambda c: (c in ";,\\") and '\\'+c or c, text)) 214 return '\\n'.join(re.split(r'[\r\n]+', s)) 215 212 216 def write_prop(name, value, params={}): 213 217 text = ';'.join([name] + [k + '=' + v for k, v in params.items()]) \ 214 + ':' + '\\n'.join(re.split(r'[\r\n]+', value))218 + ':' + escape_ics(value) 215 219 firstline = 1 216 220 while text: 217 221 if not firstline: text = ' ' + text … … 254 258 if ticket['owner'] == user]: 255 259 ticket = Ticket(self.env, tkt_id) 256 260 write_prop('BEGIN', 'VTODO') 261 write_prop('UID', '<%s/ticket/%s@%s>' % (req.base_path, 262 tkt_id, host)) 257 263 if milestone.has_key('due'): 258 264 write_prop('RELATED-TO', uid) 259 265 write_date('DUE', localtime(milestone['due']))
comment:5 by , 18 years ago
Milestone: | 0.10.1 → 0.10 |
---|---|
Status: | new → assigned |
Patch looks good. Many thanks!
Note:
See TracTickets
for help on using tickets.
The following patch against source:tags/trac-0.9.5/trac/ticket/roadmap.py fixes the defect for me
trac/ticket/roadmap.py
'\\n'.join(re.split(r'[\r\n]+', value))