Turn weekly bug report email tool into Trac plugin

Bug #377665 reported by Thijs Triemstra
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Twisted/Trac Integration
Confirmed
Medium
Thijs Triemstra

Bug Description

The Weekly Bug Report email that is send to the twisted-python mailinglist once a week, is currently a collection of modules living in exarkun's sandbox at http://twistedmatrix.com/trac/browser/sandbox/exarkun/trac. We're now also using it for our PyAMF project and it needed a few small tweaks to get it running for us. Would be nice to refactor this into a Trac plugin so it can be maintained on trac-hacks.org for example.

Related tickets: #403706, #403709, #403715, #403719

Revision history for this message
Jean-Paul Calderone (exarkun) wrote :

The part of this code which digs around in the trac database (and thus is intimately tied to trac) would very likely make sense as a trac plugin. For the rest, the graph generation, emailing, statistics, etc, I'd rather leave it independent of trac dependencies (or rather, factor it so that it /is/ independent, since it's hard to claim that it is now).

What kind of tweaks were necessary for you to get it to run? And did you get it running stand-alone, or as a trac plugin?

Revision history for this message
Thijs Triemstra (collab) wrote :

Ok, first of all, because of the way the image (png) data is embedded in the emails, mailman goes a little crazy and can't display this inline data or turn it into an attachment. So a good solution would probably be an image attachment, displayed in the .html version? Second of all, having these emails archived, so writing the .html and .png to disk, would be another must-have. This would allow us to create an archive, which then could be displayed in Trac.

So I would say that the Trac plugin:

 - pulls records from the Trac database
 - creates the stats data
 - renders the graph
 - writes .html stats and .png graph to disk
 - expose stats data through XML-RPC
 - exposes an archive view of the stats in Trac when visiting mytrac.org/stats

To tell the Trac plugin to do this every night, week, hour etc it would receive an request from a (XML-)RPC client, like a twistd application, and also return the .html and .png to that server. It's then up to that machine to email it, blog it, archive it as well etc.

Just thinking out loud here. I also managed to get py-gnuplot to work and this might be an alternative for the current graphing library.

Thoughts?

Revision history for this message
Jean-Paul Calderone (exarkun) wrote :

Sounds pretty coherent. Do you know what the story is for access controlling XML-RPC methods? It would be important to make sure arbitrary users couldn't trigger this. I assume it's straightforward, though.

I've been almost happy with matplotlib lately. I think switching to that is the thing to do. I haven't used py-gnuplot in many years, but at the time, I got a bad impression of it. :) Is there anything in particular about it you find compelling?

Revision history for this message
Thijs Triemstra (collab) wrote :

The plugin was imported here: http://bazaar.launchpad.net/%7Eexarkun/twisted-trac-integration/trunk/files/head%3A/trac-graphs/

I will open a couple of tickets for the items from my previous comment and answer your questions about XML-RPC/permissions there.

Changed in twisted-trac-integration:
assignee: nobody → Thijs Triemstra (collab)
importance: Undecided → Medium
status: New → Confirmed
Thijs Triemstra (collab)
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related blueprints

Remote bug watches

Bug watches keep track of this bug in other bug trackers.