6 ms·
it is just me or is this a bigger release than normal? Great job to the Django team, this is more proof that Django is the defacto choice when building web app
by noobhater1000 12y ago
it is just me or is this a bigger release than normal? Great job to the Django team, this is more proof that Django is the defacto choice when building web applications in Python.
Flask is good, but Django comes with many more batteries included, which all major websites need.
- getup8 12y agoI used Django a few years ago but am now learning Flask and coupled with SQLAlchemy, WTForms and a few other extensions seems to be very intuitive and powerful. Just curious, what batteries in Django make it preferable to you over Flask+SQLAlchemy+Jinja2?
- andrewfong 12y agoApparently Jinja2 will now be one of the batteries included, so there's that.
- wldcordeiro 12y agoNot so much included, it's more like the battery slot that the Django template language fits in is now easily accessible. So you can change your "Duracell" [Django Template Language] for "Energizer" [Jinja2]. But it's a pretty great change as there are legitimate times that Jinja2 is worth using over the Django system.
- nnain 12y agoI learnt Flask first and then Django. I like Django more. Figuring out which Flask package to pick is lot of unnecessary work. In most cases, you would end up using templates, ORM, Security, Forms, Admin, Migration anyway. Django's defaults for these (now including Jinja2 with this release!) are quite good. Also I found SQLAlchemy tooo complicated. Too much to learn there. It might be really cool for edge cases, but I'm happy using raw SQL when/if the Django ORM (ever) falls short of my needs. Also performance benchmarks seem to suggest that Django is faster than Flask. This was a surprise to me. As in, it seems as if Flask is leaner so would be faster, but Django performs better than flask. Also, I kinda like the Django community more.
- noobhater1000 12y agonot to mention the vast number of packages, documentation and questions and answers on stack overflow for just about every topic that exists. rest api's (no out of the box support but plenty of documentation to make your own or just go with Django-rest-framework) Built in administration system/back end. easy cache plugins, middleware extensions, GIS support with Geo-Django
- getup8 12y agoI think this has been my biggest annoyance with Flask to date. Searching Google/SO on issues I run into provide far fewer results (and often none that directly answer my question) than Django. Still probably think Flask is worth learning first though as it gets you closer to the Python core and hoping if I switch back to Django the transition will be easy enough.
- jgroszko 12y agoCould you link to some of those performance benchmarks?
- scrollaway 12y agoI make part of my living from Django work. I like Flask a lot more. It feels a lot less boilerplate-y, eg for routing, views etc. One of Flask's strongest points though is Jinja2 IMO and Django getting that is fantastic news. I couldn't agree more on SQLAlchemy, though. Django's orm is nasty perf-wise and if you want to do anything low level, but API-wise it's really great. But SQLAlchemy felt like learning something even more complex than SQL itself... It's weird this isn't a solved problem.
- baq 12y agoSQLAlchemy core basically is raw SQL in Python syntax, but better - it's composable, whereas plain SQL isn't. SQLAlchemy declarative looks similar to Django's models, except it was designed from the ground up to handle multiple transactions and DB connections, which isn't necessarily true for Django's ORM. I wouldn't be afraid to say that SQLAlchemy is a state-of-the-art tool in ORM space (not only Python ORM space). Flask-SQLAlchemy extension adds some niceties that make it look even more similar to Django's framework.
- jMyles 12y agoIf Django 1.7 is the "new normal" (and I don't think it is) then this is a comparatively small release. Django 1.7 was just huge; this is more in line with the changes in 1.5 and 1.6.
- scrollaway 12y agoJinja2, the results of the postgres kickstarter coming in, DurationField/UUIDField, integration of django-secure... this release is massive, almost bigger than 1.7.
- jsmeaton 12y ago1.7 has migrations (huge), app loading refactor (big), system check framework (big, but relatively internal), and custom lookups API (cool, but not fully utilised yet). Most of the other features were smaller niceties. 1.8 has public Meta, multiple template engines, contrib.postgres, and query expressions (my pet). Again, most other features were smaller nice to haves. I'd say the features of both are relatively on-par. Migrations probably give a false sense of scale just because that one feature was so big. As for the "new normal" comment, I agree with you. I'm not sure there are many big bang features ready to go or that have been proposed. I think 1.9 will see lots of incremental improvements and bug fixes.