IRC logger for #django

There now is a IRC logger for #django on freenode.net. Ever since the loglibrary broke down, I thought about rolling my own. So I started to build the stuff needed for an IRC logger. The interface itself is written with django, of course lachendes Gesicht

As allways, the source is available in my trac instance. It's currently only running in #django, but it can easily be extended to other channels. And it stores log lines in a database, so I will be able to add searching and stuff like that. It already has a calendar view on the logs.

The logging itself is done with muh - a nice IRC proxy that allows logging to named pipes. Then there is a script fetch.py that pulls the lines from the named pipe and stores them in the database. The last part is the django-based viewer for those logs.

Update: the logging is now done with a dedicated IRC logger written in python. It's in the source tree as loggerbot.py.

I could make use of generic views in Django, only that I needed to parameterize them. I did that with a wrapper function that moves stuff from the keywords of a view function to the extra_lookupargs and extracontext keywords of generic views. You can see the code in the repository.

The rest is just standard Django stuff: generic templates (that make use of the cool regroup tag) and some custom tags for the calendar and the user colorization. A bit of model hackery and that's it, actually. Nice and simple. Took only a few hours to bang together, and that includes playing with muh and named pipes ...

tags: Django, Programmierung, Python

C8E Oct. 2, 2005, 5:58 p.m.

Great work, Georg!

What about auto linking of [42] to http://code.djangoproject.com/changeset/42 and #42 to http://code.djangoproject.com/ticket/42 and {42} to http://code.djangoproject.com/report/42 ?

hugo Oct. 2, 2005, 6:52 p.m.

Great idea. I added a tracurl attribute to my channels model that gives the base url for a trac instance and if it is set (in #django it is set), it will be used to convert ticket numbers, changeset references and report references.