Modify

Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#10808 closed defect (fixed)

Version 0.11 using to_utimestamp instead of to_timestamp

Reported by: binnut_@… Owned by: Chris Nelson
Priority: normal Component: TracJsGanttPlugin
Severity: major Keywords: loading to_utimestamp
Cc: Trac Release: 0.11

Description (last modified by Ryan J Ollos)

The plugin wont load for me, i get the following message

Trac[loader] ERROR: Skipping "tracjsgantt = tracjsgantt": (can't import "ImportError: cannot import name to_utimestamp")

After some research i have found that it is because 0.12 uses to_utimestamp but 0.11 uses to_timestamp.

It seams that this plugin have been changed to match 0.12 in the 0.11 version, but that have introduced this loading bug.

Attachments (1)

patch10808.patch (635 bytes) - added by Chris Nelson 11 years ago.
Patch that may fix to_utimestamp() import issue.

Download all attachments as: .zip

Change History (12)

comment:1 Changed 11 years ago by Chris Nelson

Summary: [Bug] version 0.11 using to_utimestamp instead of to_timestampVersion 0.11 using to_utimestamp instead of to_timestamp

I develop and use the plugin in 0.11.6. There should be code in the plugin to make to_utimestamp() work.

What version of Trac are you using?

comment:2 Changed 11 years ago by Ryan J Ollos

Description: modified (diff)

comment:3 in reply to:  1 ; Changed 11 years ago by Ryan J Ollos

Replying to ChrisNelson:

I develop and use the plugin in 0.11.6. There should be code in the plugin to make to_utimestamp() work.

I had thought the same, but all I see is the following:

from trac.util.datefmt import to_utimestamp, localtz

If I remember correctly you have a patched version of Trac 0.11.x that uses utimestamps. Wasn't there some code such as the following implemented in the plugin at some point?:

try:
    from trac.util.datefmt import to_utimestamp
except ImportError:
    from trac.util.datefmt import to_timestamp as to_utimestamp

comment:4 Changed 11 years ago by Ryan J Ollos

Maybe this is the offending changeset?

comment:5 in reply to:  2 Changed 11 years ago by binnut_@…

Replying to rjollos: I'm using version 0.11.7.

comment:6 in reply to:  4 Changed 11 years ago by Chris Nelson

Status: newassigned

Replying to rjollos:

Maybe this is the offending changeset?

That seems very likely. Thanks for the pointer!

comment:7 in reply to:  3 Changed 11 years ago by Chris Nelson

Replying to rjollos:

Replying to ChrisNelson:

I develop and use the plugin in 0.11.6. There should be code in the plugin to make to_utimestamp() work.

I had thought the same, but all I see is the following:

from trac.util.datefmt import to_utimestamp, localtz

If I remember correctly you have a patched version of Trac 0.11.x that uses utimestamps. Wasn't there some code such as the following implemented in the plugin at some point?:

try:
    from trac.util.datefmt import to_utimestamp
except ImportError:
    from trac.util.datefmt import to_timestamp as to_utimestamp

That sounds really familiar but I can't find it anywhere on any branch in my repository.

comment:8 Changed 11 years ago by Chris Nelson

I can't push to T-H right now (some authentication failure) but I'll attach a patch that I hope will help.

Changed 11 years ago by Chris Nelson

Attachment: patch10808.patch added

Patch that may fix to_utimestamp() import issue.

comment:9 Changed 11 years ago by Chris Nelson

(In [12565]) to_utimestamp isn't in 0.11. Refs #10808.

comment:10 Changed 11 years ago by Chris Nelson

Resolution: fixed
Status: assignedclosed

Seems to be working.

comment:11 Changed 11 years ago by Ryan J Ollos

This issue had previously been reported in comment:4:ticket:10405 as well.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Chris Nelson.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


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

 
Note: See TracTickets for help on using tickets.