« Post a day in review | Year in Review »
During the last month I have proposed some conventions for Django, mostly in the realm of templates. In doing so I have looked around for other documented places where conventions are mentioned. I haven't found a really good reference for Django conventions. Brian's post was a good example of reusable app conventions, and the Pinax Project is a great reference implementation. However, I couldn't find any simple reference for regularly used conventions in the Django world.
I don't know if this will be useful for people, but I think this goes along the whole convention/pattern ideal. If we all use a common naming, syntax, and style in places where they can be arbitrary, then we gain a lot of value of being able to understand whats going on in others code. So I have started a project that hopefully will act as a reference for Django Conventions.
Currently it is pretty sparse, but I think that having that document in any form is a great step. I'd love to hear some feedback, and it needs a lot of work, so feel free to email me or leave comments here with your additions and criticisms. If this idea becomes useful, I would be fully in support of including it in the Django Documentation or something along those lines as well, but I don't know how "official" this will really be. For the moment just consider it my hair brained idea of how things should be done :) Cheers.
Posted at 10:45 p.m. on December 3, 2008
Comments: 3
Tags: conventions , django , idea , project
Django Conventions Project Update
Abstract value of conventions
The problem with Django's Template Tags
Welcome to the home of Eric Holscher on the web. I talk about software development, mostly in the realm of Django. I am interested in the real time web, testing, mobile apps, and other things.
Why Read the Docs matters
1 week, 5 days ago (Comments: 7)
Read the Docs Update
9 months, 4 weeks ago (Comments: 2)
Using Reviewboard with Git
1 year ago (Comments: 0)
Read the Docs Updates
1 year ago (Comments: 1)
Handling Django Settings Files
1 year ago (Comments: 12)
Required Reading
1 year, 2 months ago (Comments: 0)
Using Haystack to index non-database content
1 year, 2 months ago (Comments: 4)
Correct commands to check out and update VCS repos
1 year, 2 months ago (Comments: 0)
Site upgrades
1 year, 2 months ago (Comments: 0)
Building a Django App Server with Chef: Part 4
1 year, 2 months ago (Comments: 1)
Setting up Django and mod_wsgi
Building a Django App Server with Chef: Part 1
Screencast: Django Command Extensions
Big list of Django tips (and some python tips too)
Handling Django Settings Files
Lessons Learned From The Dash: Easy Django Deployment
Large Problems in Django, Mostly Solved: Delayed Execution
Building a Django App Server with Chef: Part 2


Comments
1 Malcolm Tredinnick says...
A number of these look useful, some will be slightly arbitrary and some need better phrasing (e.g. models.py and views.py assumes I would only ever have one file for those. They can be modules). However, that's all small fry.
You should probably avoid reinventing a coding style, though, and contributing.txt in the Django documentation already has a preferred ordering. Matching what Django does is probably not a bad idea in that respect. You more or less mimic that already, but putting a link in for all the cases wouldn't be a bad idea.
Posted at 5:56 a.m. on December 4, 2008
2 Camron Flanders says...
A page in the wiki on djangoproject.com seems a more appropriate place for this.
Posted at 3:53 p.m. on December 6, 2008
3 Preston Holmes says...
Wherever it lives, here or wiki - this is great for people just starting (like me) to develop good habits early.
Posted at 7 p.m. on December 19, 2008