Hello World
08 August 2011
This site is coming to life...
It is build upon Django, Django CMS, Django-Simplewiki, cmsplugin-blog and a few other bits and pieces.
I decided a while back that I wanted to reduce my dependency on PHP and that I wanted to give one of the fancy Python frameworks a go. When Storytlr decided that it did not like being migrated from CentOS 5 to Scientific Linux 6 I decided to finally ditch my conglomerate of PHP applications in favour of a streamlined and modular Python based website.
I wanted the niceties of managing content with a CMS and settled on Django CMS after checking out Pinax, which was too unstable and the community was not as active. Pinax does have a cool tool which allows you to start a project based on a site template. It'd be cool to see this idea ported to work with Django-CMS.
It's interesting that there are so many Django apps which claim to be wikis however have precisely *none* of the features you would expect from a wiki. I was lucky to stumble across Django-Simplewiki. It has a few warts but it does what I need and integrated easily. To migrate content from MediaWiki there was no scripts available but I managed to use Markdownify to migrate the articles to markdown format for Simplewiki. It's worth noting that you can easily expand Simplewikis' functionality by adding python-markdown modules. A Table Of Contents tag is very useful and is included in python-markdown. I think I should probably try cmsplugin-markup so I can write normal site content using markdown (and its extensions).
99% of development time was spent trying to understand other peoples' code so I could work around problems. It's pretty clear to me now that the Django/Python dogma of re-usability has a major hidden clause. The Django/Python community's definition of "reusable" conveniently leaves out the part where you have to spend hours understanding the inner workings (and fixing the bugs) before you can "reuse" that thing. It's a far cry from PHP land where most of the time you simply unzip the module, sync the database and you're done... Wait, isn't that more or less how it should be with Django? (ignoring templating, of course)
In terms of learning new tools I also had a few problems. I got quite confused when despite uninstalling a package in a virtual environment with pip, the old version would still be there. This was because I installed multiple versions of a package but only uninstalled one version. Once I figured this out things got a whole lot easier. Setting up mod_wsgi with the python virtual environment was initially confusing too, but once I trudged through the documentation enough things became clearer though I don't understand how I eventually fixed my problem of Django only working under mod_wsgi if DEBUG was True.
I have met a few great people while complaining about problems in bug trackers and IRC. Ojii, the lead developer (?) for Django CMS was *very* helpful and somebody emailed me yesterday saying that they might have found a fix for the rendering bug in Django-Blog-Zinnia (a great blogging app). The friendly community is what has kept me from running back to PHP with my tail between my legs.
I could have just cusomised MoinMoin or Mezzanine but where would the fun be in doing things the easy way?
Comments