Code

Opened 6 years ago

Closed 6 years ago

Last modified 5 years ago

#8300 closed (duplicate)

feedgenerator shouldn't use ascii to decode dates

Reported by: alperkanat Owned by: nobody
Component: contrib.syndication Version: master
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

if i use some locale like tr_TR.UTF-8 or any other locale, a date for the rss feed could be "10 Ağu" instead of "10 Aug".. Therefore, I get the following error messages:

UnicodeDecodeError at /feeds/latest/
'ascii' codec can't decode byte 0xc4 in position 9: ordinal not in range(128)

I think all decoding should be done using utf-8 instead of ascii.. And by the way there's a problem in line 241 of feedgenerator.py file:

handler.addQuickElement(u"pubDate", rfc2822_date(itempubdate?).decode('links'))

'links' here should be something like ascii or especially utf-8..

Attachments (0)

Change History (4)

comment:1 Changed 6 years ago by alperkanat

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

sorry the links part is my fault :)

comment:2 Changed 6 years ago by mtredinnick

How is this different from #8219 (which you also filed)?

comment:3 Changed 6 years ago by mtredinnick

  • Resolution set to duplicate
  • Status changed from new to closed

Closing as a duplicate. Please reopen with an explanation of the difference if this is different from #8219.

comment:4 Changed 5 years ago by anonymous

  • milestone post-1.0 deleted

Milestone post-1.0 deleted

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.