« Return to Thread: Sending iMIP messages with no icon-pngs fails, possible fix

Re: Sending iMIP messages with no icon-pngs fails, possible fix

by Morgen Sagen :: Rate this Message:

Reply to Author | View in Thread

Thanks -- fixed in trunk, rev 4038

~morgen

On Apr 17, 2009, at 5:33 AM, Markus Stürmer wrote:

> I think I found a small bug in
> twistedcaldav/mail.py
>
> When providing no icons,
> 1114         iconPath = self.getIconPath(details, canceled,  
> language=language)
> will set iconPath to "None" and
> 1280         if os.path.exists(iconPath) and htmlTemplate.find("cid:
> %(iconName)s") != -1:
> will fail with such an error message:
> 2009-04-17 14:23:27+0200 [-] [mailgateway] exceptions.TypeError:  
> coercing to Unicode: need string or buffer, NoneType found
>
> I catched that case by extending the test:
> 1280         if iconPath != None and os.path.exists(iconPath) and  
> htmlTemplate.find("cid:%(iconName)s") != -1:
>
> Regards,
> Markus
> _______________________________________________
> calendarserver-users mailing list
> calendarserver-users@...
> http://lists.macosforge.org/mailman/listinfo.cgi/calendarserver-users

_______________________________________________
calendarserver-users mailing list
calendarserver-users@...
http://lists.macosforge.org/mailman/listinfo.cgi/calendarserver-users

 « Return to Thread: Sending iMIP messages with no icon-pngs fails, possible fix