django-avocado

Software Screenshot:
django-avocado
Software Details:
Version: 0.9.1 Beta 9
Upload Date: 20 Feb 15
Developer: Thomas Weholt
Distribution Type: Freeware
Downloads: 0

Rating: nan/5 (Total Votes: 0)

django-avocado is a deliciously delayed and cached database logging app for Django.

The code has so far only been tested using SQLite, Django 1.3, Python 2.6.6 on Ubuntu 10.10.

Usage:

Avocado is meant to be used when you want to log huge amounts of log entries related to the same context, store the log in the db for easy sorting and viewing, and not have the performance hit of using the django orm.

You might do something like this in your view:

from avocado.context import get_context

with get_context("filescanning") as log:
 for filename in somefilescanningmethod():
 # do something with the file and store some information about it
 log.info("Did something to %s." % filename)


You can also log information and add an instance of a django model. In the admin you can see the log and click to go directly to the related model:

with get_context("UserProcessing") as log:
 for usr in User.objects.all():
 # do something with the user and store some information about it
 log.info("Did something to %s." % user, instance=user)


You can also log exceptions and avocado will try to log more than just the name of the exception being raised, but this not formatted very pretty at the moment and the code seems to bring along a lot of useless info. Still, here's how to test it:

with get_context("UserProcessing") as log:
 try:
 a = 0
 b = 2
 c = b / a
 except Exception, e:
 log.exception("Math exception: %s" % e)


You don't have to pass the exception along. Avocado will dig out lots of stuff for you.

Installation:

pip install django-avocado

or

hg clone https://bitbucket.org/weholt/django-avacado python setup.py install

Add avocado to INSTALLED_APPS. You might have to copy or symlink to the templates in the avocado-folder, but I don't think so.

What is new in this release:

  • Rewrote some to be compatible with the latest release of DSE.

Requirements:

  • Python
  • Django

Other Software of Developer Thomas Weholt

Kolibri
Kolibri

11 May 15

django-photofile
django-photofile

20 Feb 15

djftpd
djftpd

11 May 15

Comments to django-avocado

Comments not found
Add Comment
Turn on images!