“Software is hard.” reads the quote from Donald Knuth that opens Scott Rosenberg’s Dreaming in Code. Even the development of Gelman is not smooth as I expected.

Think big, but not fancy

Gelman is a hobby project to scratch personal itch, at the same time it acts as the playground to learn django and dojo. Therefore, it is extremely difficult to resist the temptation for some bling-bling but not essential features, which are called “free feature” in the industry. For example, the fancy django-registration plug-in. It will be cool to integrate a ring-and-whistle registration module, but do I really need this module since I am probably the only user/administrator of this web application, why bother to waste effort in registration?

Deodorize the smell

It is quite annoying to work on a bad structured code base with misleading name convention. Eventually, I decided to re-organize the layout of the source code, and moved out from Google Code to Assembla, since the latter provides the Trac support for online source browser and ticket support.

Some other changes include:

  • Rename library as bookshelf
  • Move the core functionality for book/add to file/add
  • Redesign and develop (in progress) the MassAdd functionality for files in server’s incoming

Find a formal way

What make Gelman stands out is his admin interface, 60% of its functionalities are only available to administrator. When working with admin module, we should play the game of default admin. Eventually, I may have to copy the code from admin module for the sake of security and behavior consistency. In this situation, the Django Book cover what is on the table, but not under the table.

Here is just a snapshot of current progress, the MassAdd.
MassAdd

Share and Enjoy:
  • Print this article!
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks

3 Comments to “Learning Django by Example(5): Software is hard”

  1. BasilNo Gravatar | December 27th, 2007 at 6:17 pm

    Nice job! Learning by example is not just another way to learn, it is the only way to learn..

    I also started learning Django very recently to build my own web applications. I notice your Trac page for the Gelman project is embedded within the context of navigation links at the very top of the page. This is nice – it allows the user to quickly jump to a different site from Trac pages.

    But how did you do it? When I study the source of the Django website, I see they use the “flatfile” approach, and somehow they use their own CSS so that their Trac pages are rendered in the green-theme “Django” look. I’d like to follow that example, but do you have any idea how to go about it?

    -basil

  2. bookstackNo Gravatar | December 28th, 2007 at 9:43 am

    To be honest, this is not my effort, it is the default Trac setting of Assembla.

    I love Trac, but so far has no time to play with it. Maybe when Gelman is stable enough for the prime time. :-)

  3. basilNo Gravatar | December 29th, 2007 at 4:42 pm

    Well, it turns out that such a customization must be done on the Trac side, not Django. I followed the directions here and it worked out very well, with minimal CSS changes.

    The downside is that Trac’s “site.html” is a separate file from my Django project’s “base.html”, so there is some duplication of effort and future maintenance issues. Unless there is some clever way to generate the site.html on the fly from Django. Hmm..

    Cheers,
    -basil

Leave a Comment

This site is using OpenAvatar based on