Live data from Hacker News

Django 3.2

djangoproject.com

51–60 of 195 posts

Re: Django 3.2

#51

Before Django the gold standard for Python web apps was Zope. What a tremendous achievement by the Django team!

I recall there being some 'wilderness years' between people generally deciding that Zope was a bad idea and Django 'winning'. I remember using frameworks like Turbogears and CherryPy for a while before Django and Flask split the 'market' between them.

Re: Django 3.2

#52

Earlier quoted context omitted.

Zope? Now, that's a name I haven't heard in a long time... A long time. I wonder of this magnificent monstrosity is still alive?

It’s still alive and underpins the CMS plone [1]. It has evolved and separated into zope [2] zodb [3] and ztk. [1] https://plone.org [2] https://zope.org [3] https://zodb.org Note: circled the link.

[deleted]

Re: Django 3.2

#53

I'm more if a flask man myself. Worked with django only when I had to. Maybe I'm wrong?

Django has a few drawbacks:

1. It’s tricky to use in non-web contexts. If you ever need something to happen as a response to an event which is not a web request, Django makes this difficult and ugly.

2. Django also more or less requires ownership of the database in order to function as intended. If you want to have your Django objects in your own database and handle schema changes centrally (to, for example, alleviate problem 1 above), you must also abstain from some of Django’s power, i.e. migrations, etc.

Re: Django 3.2

#54

I'm more if a flask man myself. Worked with django only when I had to. Maybe I'm wrong?

Honestly, I don't see the point of using Flask anymore. You can set up a Django project and just use a single module with a bunch of view functions, built-in testing and sensible defaults. Done. Not choosing that approach just because it takes a few more MBs on disk or needs a few more KBs of memory is shortsighted, IMO. You can't always predict what a project will end up needing.

I'm legitimately asking: why would you use Flask instead of Django, even if you don't (but might) need the ORM, admin etc.? Thanks!

Re: Django 3.2

#55

Congratulations to the Django project and contributors on a big LTS release. And a huge thank you for the consistently excellent framework that so many have built their web dev careers on. I'll post this as a Show HN soon, but I'll mention it now as a soft-launch introduction. After a decade of using Django I started a project I always wanted to exist: backported security and bug fixes to old versions that the Django…

This is awesome, good luck! It's a project/business that I've suggested a few times on the mailing lists and I'm truly surprised it's taken this long for someone to start one up. I'll be interested to see how/if the price points change over time. The pro tier is approximately equivalent to <= 5 hours of developer time per month. At a minimum it gives useful information to developers trying to communicate the cost of…

Thanks! I toyed with the idea since 2014, after I was stuck managing a Django codebase with a gnarly middleware for a multi-tenanted website that precluded an easy upgrade.

I bookmarked this thread in 2019 where tptacek provided the impetus for the project with a one-liner suggestion https://news.ycombinator.com/item?id=20378409 And I've just noticed you replied then too!

I also assumed someone would get around to it. It took a while to get to a place I could start and then way longer to develop than I assumed. (Not just the backports but the tooling, testing infra, and website)

That's good to hear on pricing since it reflects my experience and is my thinking behind the initial price points.

Re: Django 3.2

#56
Django rocks. I have been using it in every side project of mine since 2016. Love it, recommend it especially for teams with very less time and more features on backend.

Re: Django 3.2

#57
post #38

Earlier quoted context omitted.

The ORM is horrendous.

Can you elaborate? I've been using it for years and it mostly does what I want. It's an ORM and obviously sometimes generates unefficient queries I need to manually amend/refactor but otherwise I don't see any major issues with it? In contrast I've looked at SQLAlchemy with Flask and I couldn't even wrap my head around declaring models (which inherit from the DB connection object if I remember correctly, so potential…

Comparing Django vs SQLAlchemy, Django's weakest point is its extremely static ORM syntax. The double underscore separation (e.g. user__group__name__icontains) for query parameters is likely my biggest pet peeve as it requires me to unroll unchecked strings together into a big garbled mess. I would have much appreciated being able to use more code-verbose query tools; the moment you have to go into building more dynamic user-defined query systems, Django's ORM just becomes a hindrance.

I also noticed the second part of the comment: Django does a lot of Python magic in the background through extensive use of reflection and class-level declarations, this hides away the abstractions (again) at the propose benefit of ease of use. And well, it is easy to use. For certain applications. I just personally found a lot of footguns trying to work with more advanced Postgres functionality (mainly around JSON) and it took a while to write my own abstractions atop the Django ORM to get to a comfortable level.

Re: Django 3.2

#58
post #12

Earlier quoted context omitted.

Depends what you want to do, and why you're doing it. Very often when I make something in Flask, I end up with so many dependencies it might as well be Django (but without the cohesion). On the other hand, Django might be overkill in some situations (e.g. a small API without a relational database backend).

I was forced to fall on this trap once: a guy has a small Flask app up and running, and he asked for help to implement: an ORM with migrations, an Admin and form validation (among other things that had nothing to do with Django such file parsing). I suggested to migrate the app from Flask to Django while it was small and simple, but he refused for Django is "too big and complicated". OK, then. We ended up creating a…

but he refused for Django is "too big and complicated". OK, then. We ended up creating a monstrosity of Flask half-assed packages to include functionality that is already included in Django (think cache, csrf, admin...), plus WTForms, plus SQLAlchemy, plus Alembic, hard to test, hard to keep updated, hard to deploy...

Heh. I've done that. Impressive how quickly you can go from "I literally need three or four REST end points to let users query this SQLite database" to, well that.

Re: Django 3.2

#59
post #44

Congratulations to the Django project and contributors on a big LTS release. And a huge thank you for the consistently excellent framework that so many have built their web dev careers on. I'll post this as a Show HN soon, but I'll mention it now as a soft-launch introduction. After a decade of using Django I started a project I always wanted to exist: backported security and bug fixes to old versions that the Django…

This is a great idea...unfortunately a company that skips on Django security patches and bug fixes will very likely be doing the same for everything else (frontend libraries, servers, etc). But there's not much you can do when you're stuck on a feature-factory treadmill, and this looks like a cost-effective way to ameliorate the problem.

Yes, that's why I optimistically chose a generic name for the project. Django is a solid start and I sure have tons more work to do.

Then there's an opportunity to expand to adjacent projects it could make sense to cover.

There's lots of thinking to do, approaches to try around funding the original projects and authors, and happily aligning incentives.

Re: Django 3.2

#60
post #43

Earlier quoted context omitted.

It’s still alive and underpins the CMS plone [1]. It has evolved and separated into zope [2] zodb [3] and ztk. [1] https://plone.org [2] https://zope.org [3] https://zodb.org Note: circled the link.

I remember being quite interested in zodb for app development in python since it alleviates the need for an orm... it is a bit like a document store, right?

Yes indeed it is and also comes with High availability and horizontal scaling. It’s is an object store but is ACID compliant.
Post reply on HN