Django Project Structure Test
by Justin Michalicek on July 14, 2013, 11:08 p.m. UTCI've started a second small to mid sized project to go along with Djukebox. I'm using this to test something out with Django projects to see what I prefer. With Djukebox I just made it a proper installable app that you can install with pip (if I put it on pypi). I like this because then you can easily start a project called whatever you want, which does anything you want, and add Djukebox to it. It also makes it easy to distribute without tying myself or anyone else to a specific project structure, you set up your Django project however you want and just install Djukebox. The downside to that method is that now everything has to go in the Djukebox app and it will just continue to get larger and larger as I build it. In an ideal world Django projects are made up of many small apps. To do that using the standard python install apps would result in many small git repos being maintained, installed, and kept in synch for a single project. I don't really like that.
My new project is using a more standard setup where the whole project will be in a git repo and will contain many apps. This has its own issues, which are what I wanted to avoid with how I have handled Djukebox. By doing this I'm adding many apps that end up in the global package namespace, so I have to make sure not to name any apps something that conflicts with an already established package (which I have run into doing this in the past), and of course you can't just pip install the app and use it anywhere, now it has to be just this project. The plus side is that I can break things up into many small apps with just a few models and urls rather than one app which grows and grows.