One of the tasks that I seem to repeatedly do across multiple projects, is extend the built-in paginator from Django. The built-in is fairly nice, but it’s quite honestly extremely confusing as you have to pass around a paginator instance as well as a paginator.page() instance in order to get useful pagination inside of a [...]
Posts Filed in "Django"
I was helping someone today in the Django IRC channel and the question came across about storing a denormalized data set in a single field. Typically I do such things by either serializing the data, or by separating the values with a token (comma for example). Django has a built-in field type for CommaSeparatedIntegerField, but [...]
I was working on our search for the new iBegin today, which utilizes Sphinx, Django, and obviously, django-sphinx. Being the person who hates doing tedious work, I found a few issues in the newly done configuration generation. Errors hardcore in 0.98 It wasn’t generating attributes for floats (latitude/longitude) Didn’t work with custom index names So [...]
I’ve been annoyed for the last 6 months of using Jinja, as I’ve been working on numerous different Django projects, and I’ve had to use django-admin.py vs manage.py. The reason for this is simply, that in my settings.py I had used the djangosupport.configure() routine. I tried moving it to other locations, but they didn’t seem [...]
I posted another one of my small pluggable apps up on Google code the other day. It’s called django-object-view-tracking and is most suited for tracking things such as if a user has viewed a thread in a forum. The API is fairly simple, but may need some improvements based on feedback: def view_thread_list(request): threads = [...]
I pushed an update to the django-sphinx repository tonight which includes a sample configuration generation tool. It allows you to generate a source and index config for a Model based on it’s field type. For example: from nibbits.maps.models import Map import djangosphinx output = djangosphinx.generate_config_for_model(Map) print output This will give you something like: source base [...]
I’m going to be giving a talk at DjangoCon, “High Performance Django”. I will be discussing what I’ve done at the past with Curse.com, what we do presently for iBegin’s Crazy Datastore, and general tips for scalability and performance in large web applications. So why am I telling you all of this? I’m interested in [...]
12
Jun
The Woes of Moving
I’ve been out of touch for a little over a month now as I’ve been transitioning from the west to east coast. I decided it would be “fun” to head back to my hometown for the summer, and fun it has been. While looking for a place I had been using tethering on my AT&T [...]
12
May
django-db-log
The question came up today, if there was a database logging solution available for Django. It turned out (to my knowledge) there wasn’t. So I quickly came up with django-db-log. It’s a simply middleware which will catch exceptions in Django, and log them to the database, allowing you to easily view them via the admin [...]
14
Apr
Jinja 2 is Coming
The guys over at Pocoo have been hard at work on Jinja 2 lately. So far it’s looking awesome. The benchmarks are outstanding (putting it even further ahead of Django, and faster than Mako even), and some of the additions, and changes, such as the awesome addition to for x in iterable [if expr] are [...]
