[Calendar and Contacts Server] #423: getIconPath does not cope with UTF-8 month names
#423: getIconPath does not cope with UTF-8 month names ----------------------------------+----------------------------------------- Reporter: mail@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | Radar: ----------------------------------+----------------------------------------- the getIconPath tries to look for an Icon with the month name in it. Does this really make sense does the apple version of the calendarserver have different icons per language??! I need: {{{ Index: CalendarServer/twistedcaldav/mail.py =================================================================== --- CalendarServer/twistedcaldav/mail.py (Revision 7209) +++ CalendarServer/twistedcaldav/mail.py (Arbeitskopie) @@ -990,7 +990,7 @@ with translationTo(language) as trans: monthName = trans.monthAbbreviation(month) iconName = "%02d.png" % (day,) - iconPath = os.path.join(iconDir, monthName, iconName) + iconPath = os.path.join(iconDir, monthName.encode("utf-8"), iconName) if not os.path.exists(iconPath): # Try the generic (numeric) version iconPath = os.path.join(iconDir, "%02d" % (month,), iconName) }}} -- Ticket URL: <http://trac.calendarserver.org/ticket/423> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#423: getIconPath does not cope with UTF-8 month names ----------------------------------+----------------------------------------- Reporter: mail@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | Radar: ----------------------------------+----------------------------------------- Comment(by mail@…): Exception if the error is somewhere else: {{{2011-03-17 22:30:20+0100 [-] [mailgateway] 2011-03-17 22:30:20+0100 [-] [twistedcaldav.mail.MailHandler#debug] Mail gateway created token 2c8589d3-36e6-45c1-a54e-1e75edfe0579 for mailto:xxx@felixmoeller.de (originator), mailto:xxx@derklecks.de (recipient) and 243525d6-4082-4708 -b9fa-52b8c90e9ef6 (icaluid) 2011-03-17 22:30:20+0100 [-] [mailgateway] 2011-03-17 22:30:20+0100 [-] [twext.web2.server#info] Exception rendering: 2011-03-17 22:30:20+0100 [-] [mailgateway] 2011-03-17 22:30:20+0100 [-] [twext.web2.server#error] [Failure instance: Traceback: <type 'exceptions.UnicodeEncodeError'>: 'ascii' codec can't encode character u'\xe4' in position 37: ordinal not in range(128) 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:345:errback 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:424:_startRunCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:441:_runCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:949:gotResult 2011-03-17 22:30:20+0100 [-] [mailgateway] --- <exception caught here> --- 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:891:_inlineCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/python/failure.py:338:throwExceptionIntoGenerator 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/resource.py:310:renderHTTP 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:891:_inlineCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/python/failure.py:338:throwExceptionIntoGenerator 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twext/web2/static.py:127:renderHTTP 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:891:_inlineCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/python/failure.py:338:throwExceptionIntoGenerator 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twext/web2/resource.py:109:renderHTTP 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:893:_inlineCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/mail.py:334:http_POST 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/mail.py:937:outbound 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/mail.py:1004:generateEmail 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/mail.py:991:getIconPath 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/genericpath.py:18:exists 2011-03-17 22:30:20+0100 [-] [mailgateway] ] 2011-03-17 22:30:20+0100 [-] [caldav-0] [AuthorizedHTTPGetter,client] /usr/lib/python2.6/site-packages/twisted/web/error.py:53: exceptions.DeprecationWarning: BaseException.message has been deprecated as of Python 2.6 2011-03-17 22:30:20+0100 [-] [caldav-0] [AuthorizedHTTPGetter,client] [twistedcaldav.scheduling.imip#error] Could not do server-to-imip request : <twistedcaldav.scheduling.imip.ScheduleViaIMip object at 0x9ffb32c> 500 Internal Server Error 2011-03-17 22:30:20+0100 [-] [caldav-0] [AuthorizedHTTPGetter,client] [twistedcaldav.scheduling.scheduler.ScheduleResponseQueue#error] Error during PUT for mailto:xxx@derklecks.de: iMIP request failed }}} -- Ticket URL: <http://trac.calendarserver.org/ticket/423#comment:1> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#423: getIconPath does not cope with UTF-8 month names ----------------------------------+----------------------------------------- Reporter: mail@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | Radar: ----------------------------------+----------------------------------------- Comment(by mail@…): Exception if the error is somewhere else: {{{ 2011-03-17 22:30:20+0100 [-] [mailgateway] 2011-03-17 22:30:20+0100 [-] [twistedcaldav.mail.MailHandler#debug] Mail gateway created token 2c8589d3-36e6-45c1-a54e-1e75edfe0579 for mailto:mail@felixmoeller.de (originator), mailto:felix@derklecks.de (recipient) and 243525d6-4082-4708 -b9fa-52b8c90e9ef6 (icaluid) 2011-03-17 22:30:20+0100 [-] [mailgateway] 2011-03-17 22:30:20+0100 [-] [twext.web2.server#info] Exception rendering: 2011-03-17 22:30:20+0100 [-] [mailgateway] 2011-03-17 22:30:20+0100 [-] [twext.web2.server#error] [Failure instance: Traceback: <type 'exceptions.UnicodeEncodeError'>: 'ascii' codec can't encode character u'\xe4' in position 37: ordinal not in range(128) 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:345:errback 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:424:_startRunCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:441:_runCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:949:gotResult 2011-03-17 22:30:20+0100 [-] [mailgateway] --- <exception caught here> --- 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:891:_inlineCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/python/failure.py:338:throwExceptionIntoGenerator 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/resource.py:310:renderHTTP 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:891:_inlineCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/python/failure.py:338:throwExceptionIntoGenerator 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twext/web2/static.py:127:renderHTTP 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:891:_inlineCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/python/failure.py:338:throwExceptionIntoGenerator 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twext/web2/resource.py:109:renderHTTP 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twisted/internet/defer.py:893:_inlineCallbacks 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/mail.py:334:http_POST 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/mail.py:937:outbound 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/mail.py:1004:generateEmail 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/site- packages/twistedcaldav/mail.py:991:getIconPath 2011-03-17 22:30:20+0100 [-] [mailgateway] /usr/lib/python2.6/genericpath.py:18:exists 2011-03-17 22:30:20+0100 [-] [mailgateway] ] 2011-03-17 22:30:20+0100 [-] [caldav-0] [AuthorizedHTTPGetter,client] /usr/lib/python2.6/site-packages/twisted/web/error.py:53: exceptions.DeprecationWarning: BaseException.message has been deprecated as of Python 2.6 2011-03-17 22:30:20+0100 [-] [caldav-0] [AuthorizedHTTPGetter,client] [twistedcaldav.scheduling.imip#error] Could not do server-to-imip request : <twistedcaldav.scheduling.imip.ScheduleViaIMip object at 0x9ffb32c> 500 Internal Server Error 2011-03-17 22:30:20+0100 [-] [caldav-0] [AuthorizedHTTPGetter,client] [twistedcaldav.scheduling.scheduler.ScheduleResponseQueue#error] Error during PUT for mailto:felix@derklecks.de: iMIP request failed }}} -- Ticket URL: <http://trac.calendarserver.org/ticket/423#comment:2> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#423: getIconPath does not cope with UTF-8 month names ----------------------------------+----------------------------------------- Reporter: mail@… | Owner: sagen@… Type: Defect | Status: new Priority: 2: Expected | Milestone: CalendarServer-3.x Component: Calendar Server | Severity: Other Keywords: | Radar: ----------------------------------+----------------------------------------- Changes (by wsanchez@…): * owner: wsanchez@… => sagen@… * priority: 5: Not set => 2: Expected * milestone: => CalendarServer-3.x -- Ticket URL: <http://trac.calendarserver.org/ticket/423#comment:3> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#423: getIconPath does not cope with UTF-8 month names -----------------------------------+---------------------------------------- Reporter: mail@… | Owner: sagen@… Type: Defect | Status: closed Priority: 2: Expected | Milestone: CalendarServer-3.x Component: Calendar Server | Severity: Other Resolution: Software changed | Keywords: Radar: | -----------------------------------+---------------------------------------- Changes (by wsanchez@…): * status: new => closed * resolution: => Software changed Comment: r7843 -- Ticket URL: <http://trac.calendarserver.org/ticket/423#comment:4> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#423: getIconPath does not cope with UTF-8 month names -----------------------------------+---------------------------------------- Reporter: mail@… | Owner: sagen@… Type: Defect | Status: closed Priority: 2: Expected | Milestone: CalendarServer-3.1 Component: Calendar Server | Severity: Other Resolution: Software changed | Keywords: Radar: | -----------------------------------+---------------------------------------- Changes (by wsanchez@…): * milestone: CalendarServer-3.x => CalendarServer-3.1 -- Ticket URL: <http://trac.calendarserver.org/ticket/423#comment:5> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
#423: getIconPath does not cope with UTF-8 month names -----------------------------------+---------------------------------------- Reporter: mail@… | Owner: sagen@… Type: Defect | Status: closed Priority: 2: Expected | Milestone: CalendarServer-3.1 Component: Calendar Server | Severity: Other Resolution: Software changed | Keywords: Radar: | -----------------------------------+---------------------------------------- Comment(by wsanchez@…): Also, if the icons contain text, as these do, then yes, it makes sense to have different icons per language. -- Ticket URL: <http://trac.calendarserver.org/ticket/423#comment:6> Calendar and Contacts Server </> HTTP/WebDAV/CalDAV Server
participants (1)
-
Calendar and Contacts Server