Edgewall Software
Modify

Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#12799 closed defect (fixed)

RSS of timeline shows incorrectly same time for all entries

Reported by: Jun Omae Owned by: Ryan J Ollos
Priority: normal Milestone: 1.3.2
Component: timeline Version:
Severity: normal Keywords:
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

$ curl -s 'https://trac.edgewall.org/timeline?max=10&format=rss' | grep -F '<pubDate>'
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>
      <pubDate>Sun, 07 May 2017 22:00:00 GMT</pubDate>

Attachments (0)

Change History (4)

comment:1 by Ryan J Ollos, 5 years ago

Looks like a regression in r15713.

  • trac/timeline/templates/timeline.rss

    diff --git a/trac/timeline/templates/timeline.rss b/trac/timeline/templates/timeline.rss
    index 75347908d..7ded61e22 100644
    a b  
    3737      # with author = event.author
    3838      #   include 'author_or_creator.rss'
    3939      # endwith
    40       <pubDate>${http_date(event.date)}</pubDate>
     40      <pubDate>${http_date(event.datetime)}</pubDate>
    4141      <link>${abs_url}</link>
    4242      <guid isPermaLink="false">${abs_url}/${event.dateuid}</guid>
    4343      <description>${

is a partial patch, though I didn't realize dateuid field was used in rss template, so that also needs to be fixed.

Last edited 5 years ago by Ryan J Ollos (previous) (diff)

comment:2 by Ryan J Ollos, 5 years ago

Owner: set to Ryan J Ollos
Status: newassigned

I'll add test coverage.

  • trac/timeline/templates/timeline.rss

    diff --git a/trac/timeline/templates/timeline.rss b/trac/timeline/templates/timeline.rss
    index 75347908d..f4369c366 100644
    a b  
    3737      # with author = event.author
    3838      #   include 'author_or_creator.rss'
    3939      # endwith
    40       <pubDate>${http_date(event.date)}</pubDate>
     40      <pubDate>${http_date(event.datetime)}</pubDate>
    4141      <link>${abs_url}</link>
    42       <guid isPermaLink="false">${abs_url}/${event.dateuid}</guid>
     42      <guid isPermaLink="false">${abs_url}/${event.datetime_uid}</guid>
    4343      <description>${
    4444      event.render('description', context)|forceescape
    4545      }</description>
  • trac/timeline/web_ui.py

    diff --git a/trac/timeline/web_ui.py b/trac/timeline/web_ui.py
    index 2395a14c7..9271d1677 100644
    a b class TimelineModule(Component):  
    375375        localized_date = truncate_datetime(localized_datetime)
    376376        datetime_uid = to_utimestamp(localized_datetime)
    377377        return {'kind': kind, 'author': author, 'date': localized_date,
    378                 'datetime': localized_datetime, 'render': render,
     378                'datetime': localized_datetime, 'datetime_uid': datetime_uid,
     379                'render': render,
    379380                'unread': lastvisit and lastvisit < datetime_uid,
    380381                'event': event, 'data': data, 'provider': provider}

comment:3 by Ryan J Ollos, 5 years ago

Resolution: fixed
Status: assignedclosed

Regression test committed to 1.2-stable in r15885. Regression test and fix committed to trunk in r15886.

comment:4 by Jun Omae, 5 years ago

Thanks for the fixing and deploying! I'm retrieving changes with Thunderbird via rss feed now.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Ryan J Ollos to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.