Opened 5 years ago

Closed 15 months ago

#6426 closed defect (fixed)

Missing YAHOO logger widget JavaScript file

Reported by: olle.jonsson+tractickets@… Owned by: rjollos
Priority: normal Component: TracTicketStatsPlugin
Severity: normal Keywords: javascript
Cc: Trac Release: 0.11

Description (last modified by rjollos)

I'm using the stats plugin with Python 2.5, but it kind of works.

There is one thing, in the JavaScript, that bothers me: a YAHOO widget for logging is not included, and this fires a JS error.

<script type="text/javascript"> 
var myLogReader = new YAHOO.widget.LogReader("myLogger");

To fix this, include this where you include the scripts.

Version used: /usr/lib/python2.5/site-packages/Tracticketstats-2.1-py2.5.egg

Attachments (1)

LoggerEnabled.png (44.8 KB) - added by rjollos 4 years ago.

Download all attachments as: .zip

Change History (4)

Changed 4 years ago by rjollos

comment:1 Changed 4 years ago by rjollos

  • Description modified (diff)

I can confirm the error on Ubuntu 10.04, Trac 0.11.7, TracTicketStatsPlugin 2.1, and Firefox 3.6.8.

The error I see in the Firefox Error Console is:

Error: YAHOO.widget.LogReader is not a constructor
Source File: http://localhost:8000/tracdev/ticketstats
Line: 164

I patched as you suggested:

  • greensauce.html

    1616    <script type="text/javascript" src=""></script> 
    1717    <script type="text/javascript" src=""></script> 
    1818    <script type="text/javascript" src=""></script> 
     19        <script type="text/javascript" src=""></script> 
    1920    <!-- OPTIONAL: Connection (enables XHR) --> 
    2021    <script type="text/javascript" src=""></script> 
    2122    <!-- Source files --> 

However, now there is an error console at the bottom of the page:

I know nothing about javascript, so I need some guidance on the best way to fix this issue. Should we:

  • Add some sort of debug flag that causes the logger to be included?
  • Remove the logger code from the production version?

The logger code is form lines 145:149,

<div id="myLogger"></div>
<script type="text/javascript">
var myLogReader = new YAHOO.widget.LogReader("myLogger");

comment:2 Changed 4 years ago by rjollos

  • Owner changed from echo0101 to rjollos

Reassigning ticket to new maintainer.

comment:3 Changed 15 months ago by rjollos

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

debug flag was added in [13191].

Add Comment

Modify Ticket

as closed .
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from rjollos. Next status will be 'closed'.
The resolution will be deleted. Next status will be 'reopened'.

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

Note: See TracTickets for help on using tickets.