Edgewall Software
Modify

Ticket #1563 (closed defect: fixed)

Opened 7 years ago

Last modified 5 years ago

Timeline gives wrong time for wiki edits

Reported by: PBruin Owned by: cmlenz
Priority: high Milestone: 0.9.6
Component: timeline Version: devel
Severity: major Keywords: timeline, wiki, edit
Cc:
Release Notes:
API Changes:

Description

I have done 5 page edits over the last hour or so. The time line shows all these edits with the same time as the very first edit. So the first page was edited at 13:56 and the last at 14:40 but all show 13:56 as the change time.

BTW, is there something to block the google adverts? The block the ticket edit box on my screen so I can not really see what I am typing, this very very anoying.

Attachments

Change History

comment:1 Changed 7 years ago by PBruin

  • Priority changed from normal to high
  • Severity changed from normal to major

The time displayed for wiki page updates is the time that the server was last restarted.
I rebooted my restarted my server at 13:56 and all wiki changes stayed on this time even after committing several changesets. Now I restarted the server again and have the same time as of the latest restart.

comment:2 Changed 7 years ago by eblot

I also saw some weird issues with the time management (on my own Apache2 server)

I've commited a couple of changes to SVN, then I've updated a Wiki page about these changes.

The timeline shows that I first wrote the changes in the Wiki, then committed the files, and the time reported is about 35 minutes late for the Wiki page edition (02:24 whereas I wrote it a 3:01).

I did not spent time (yet) to try to reproduce this bug.

I can ssh on the server, so I'm sure the date on the server is correct (an both the client and the server are up-to-date thanks to NTP)

comment:3 Changed 7 years ago by cmlenz

What python version and what Trac front-end are you using?

comment:4 Changed 7 years ago by PBruin

mod_python and python 2.3

comment:5 Changed 7 years ago by PBruin

This patch fixes the problem for me. It is probably not the best of styles but it works. Is it some python incompatibility?

Index: model.py
===================================================================
--- model.py	(revision 1680)
+++ model.py	(working copy)
@@ -103,7 +103,9 @@
             db.commit()
         self.version = 0
 
-    def save(self, author, comment, remote_addr, t=time.time(), db=None):
+    def save(self, author, comment, remote_addr, t=0, db=None):
+        if t == 0:
+           t = time.time()
         if not db:
             db = self.env.get_db_cnx()
             handle_ta = True

comment:6 Changed 7 years ago by cmlenz

  • Owner changed from jonas to cmlenz
  • Status changed from new to assigned

Oh wow, that's a bad mistake :-P

Thanks for tracking it down!

comment:7 Changed 7 years ago by cmlenz

  • Resolution set to fixed
  • Status changed from assigned to closed

Fixed in [1682].

comment:8 Changed 5 years ago by Lawrence Lo <lawrielo@…>

  • Milestone changed from 0.9 to 0.9.6
  • Resolution fixed deleted
  • Status changed from closed to reopened

Please see trac ticket 4271. I'm using tracd and python 2.3.5. It was working but after creating a custom field in the ticket I think this problem started to occur. I have been using trac for six months and had no issues until now.

comment:9 Changed 5 years ago by ThurnerRupert

  • Resolution set to fixed
  • Status changed from reopened to closed

was reopened with hint to #4271

comment:10 Changed 5 years ago by PBruin

  • Cc peter.bruin@… removed
View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
The resolution will be deleted. Next status will be 'reopened'
to The owner will be changed from cmlenz. Next status will be 'closed'
Author


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

 
Note: See TracTickets for help on using tickets.