Hacker News new | ask | show | jobs
by fbdab103 1218 days ago
I will take a well curated package that handles all the problems for me rather than bolting together pieces just so I can feel more ownership of a project.

- Admin panel? Django has me

- Web forms? Django has me

- Testing? Django, again has an out of the box solution

- Latest in security practices[0]? Again, covered for free

Flask, boy oh boy. I want an ORM? Guess I have to search around, Flask-SQLAlchemy has a lot of hits, I guess? Emails? Well, the Flask Mega-Tutorial uses Flask-Mail[1], guess I will use that. Oh look, it has not been updated since 2014[2]. Hope there is not a security flaw in there[3].

Django follows best practices, and has a huge community ensuring that there is adequate coverage and features required for modern development.

[0]: https://docs.djangoproject.com/en/4.2/releases/4.2/ note on the BREACH attack

[1]: https://blog.miguelgrinberg.com/post/the-flask-mega-tutorial...

[2]: https://github.com/mattupstate/flask-mail

[3]: https://github.com/mattupstate/flask-mail/issues/189

2 comments

FastAPI is the better choice now as its ecosystem is much more up to date and has more batteries included than flask (eg FastAPI has authentication included).
Well no. None of these thing are appealing to me. As much as I hate the modern web, admin panels and forms generated server side are dead. Testing has never been an issue. As for security practices, this statement is as subjective as they come.

I am by no means a fan of flask. However it gives you a lot more freedom to structure your application to your taste. Django is basically a php 5.4 framework with a python syntax.

In this day and age fastAPI is a solid choice, so is falcon and probably half a dozen others.