Live data from Hacker News

Django for a Rails Developer

uswaretech.com

31–33 of 33 posts

Re: Django for a Rails Developer

#31
post #18

I work with Django for a living but the lack of init/buildout in a new project has always driven me a bit nuts, I guess it's one of my development pet-peeves. I've never had project that didn't need: - a project-wide templates/ directory - media/[css|img|js] directories - some kind of database setup by default - contrib.admin (well, I created a form mailer once that had no admin) Django seems to take a "we don't want…

And your script probably sets things up differently from everyone else's :) But if you think it's a problem, why not publish whatever you use and encourage others to use it as well? (also, FWIW I don't have such a script -- a new site at work always simply inherits default settings from other stuff, and those defaults are set up to match how our production servers work)

> And your script probably sets things up differently from everyone else's :)

I don't doubt it. Much like how there is the occasional "this is how I handle managing multiple settings for different systems" blog post, people have come up with their own systems because Django provides none.

> But if you think it's a problem, why not publish whatever you use and encourage others to use it as well?

http://github.com/tvon/django-gig

Written for personal use, so...

There is also "create project" or "project template", I forget the exact name, but it's on bitbucket or github... and "paster" from zopeskel seems to have potential to do something like this but it may be too zope specific, I don't know.

There are ways to do it, but IMO it's something the framework should be handling. As it stands, "basic setup and configuration" is a much higher hurdle in Django than it is in Rails.

> (also, FWIW I don't have such a script -- a new site at work always simply inherits default settings from other stuff, and those defaults are set up to match how our production servers work)

Well, you don't have a script that builds things out in a certain way, but you have a system in place that handles project defaults.

Re: Django for a Rails Developer

#32
post #6

Earlier quoted context omitted.

Actually, if you apply the MVC paradigm, the Django View is a mix of View and Controller. Admittedly a little confusing

Hence, it is defined as MTV.

but Google thinks its MVT.

http://www.google.com/search?q=django+mvt

http://www.google.com/search?q=django+mtv

Re: Django for a Rails Developer

#33
post #5

For me the hardest thing about Django was comprehending that the 'View' is doing most of the work. * urls point to views * views do stuff. Perhaps hard, manly stuff. Perhaps involving models. Django views have hard, beefy beceps. They're awfully controlling. * the view passes a dict of results to the template, which is sent as a response to the browser. Once you get that, it's not so hard.

Actually i would prefer it if models do most of the major work. And views to convert them into a format suitable for presentation. Sometimes that not possible, but it just feels cleaner and more manageable if it is.
Post reply on HN