Live data from Hacker News

Django 3.2

djangoproject.com

111–120 of 195 posts

Re: Django 3.2

#111

I haven't used Django except as an ORM and it was a terrible experience. Anytime I wanted to update an existing relationship, it was a pain. I've heard a lot of good stuff about it when used as a web framework but I was really baffled by the ORM.

What was so painful about it? Unless you're making some really significant changes to your models, Django's migration commands handle 99.9% of cases including most common edge cases. I can't imagine it being any easier, and certainly haven't seen any other web frameworks handling migrations any better.

Re: Django 3.2

#112

I haven't used Django except as an ORM and it was a terrible experience. Anytime I wanted to update an existing relationship, it was a pain. I've heard a lot of good stuff about it when used as a web framework but I was really baffled by the ORM.

I've found the Django ORM to be, in my own opinion, one of the easiest ORMs to hit the ground running with. What was the confusing aspect of updating relational data for you?

Re: Django 3.2

#113
post #93

For those of you with a big portfolio of apps, how do you handle framework updates? Scheduled housekeeping once a quarter? Ad hoc? Ignore them until a disaster happens then panic?

The necessary changes with your use of the framework are pretty minimal so it's easy enough to keep pace on about a quarterly basis.

Usually the only friction is if there is a third party library/app you're using that doesn't yet support the newer version of Django.

Re: Django 3.2

#114
Django is a sensational piece of open source software - I've used it on so many projects.

Seen some replies saying it's a pain to deploy - look at guides for Heroku and Google's App Engine - both are super simple processes. If you want more control AWS Lightsail also has a great guide.

Re: Django 3.2

#115

Django is the gold standard for consistently pushing out reliable, well documented open source software without any marketing fluff or other bs. The amount of value the team is adding to the world can't be overstated.

A couple of years ago(2014) I made my first Python website and really enjoyed, however when it was time to put it onlin I quickly discovered that setting up hosting and configuring it was as large a task in getting to know pip, env, unicorn, apache2 and a plethora of other software to host it, is this still the case? Becaue this is what keeps me of hosting websites with python.

I just migrated to PythonAnywhere.com and it was a breeze. They also have browser access to command line, REPL, Jupyter notebooks too.

Re: Django 3.2

#116
post #17

If anyone is curious I just updated my Docker / Django starter project to use 3.2. It uses Docker Compose + Django + Celery + PostgreSQL + Redis + Webpack + TailwindCSS and it's available at: https://github.com/nickjj/docker-django-example As an aside it's also using TailwindCSS 2.1 with the JIT compiler enabled.

This is awesome, thanks for sharing. I maintain a similar boilerplate (graphene + semantic ui).

What's your take on Tailwind so far? I've found the lack of a react offering has really slowed me down.

Re: Django 3.2

#117

Earlier quoted context omitted.

A couple of years ago(2014) I made my first Python website and really enjoyed, however when it was time to put it onlin I quickly discovered that setting up hosting and configuring it was as large a task in getting to know pip, env, unicorn, apache2 and a plethora of other software to host it, is this still the case? Becaue this is what keeps me of hosting websites with python.

I had similar issues with Django where I felt that running on localhost was fine, but getting it production ready was a headache. Huge shoutout to dokku[1] which I used on my latest deployment and it makes it super easy. Lets encrypt support was the easiest I've seen and you redeploy with git push. [1] https://dokku.com/docs/getting-started/installation/

This was a huge pain for me in the past to the point that I started maintaining a boilerplate to avoid it [0]. But I've heard so many good things about dokku that I think I'll give them a try soon.

0 - https://github.com/dopeboy/django-react-docker-heroku

Re: Django 3.2

#118

Earlier quoted context omitted.

A couple of years ago(2014) I made my first Python website and really enjoyed, however when it was time to put it onlin I quickly discovered that setting up hosting and configuring it was as large a task in getting to know pip, env, unicorn, apache2 and a plethora of other software to host it, is this still the case? Becaue this is what keeps me of hosting websites with python.

You can always shortcut things by using Docker

Adding an extra layer doesn't make things simpler. It may make it easier to do a second time, but the initial set up is just the same.

Re: Django 3.2

#119

Any one have any pointers to learn the Django stack from the basics? Any specific video course or a book? "Two Scoops of Django" was recommended to me by someone on HN. I think it is currently being worked on for Django 3. It is on my reading list.

The official Django tutorial is pretty good. Two Scoops is good for going from beginner / intermediate to intermediate / advanced knowledge, with best practices in mind.

Re: Django 3.2

#120
post #83

It's a shame that Django's templates are still so bad. You can't just import and call some arbitrary python function. You most likely need to write a template filter or tag [0]. Maybe there's a good reason for this but it just feels like I'm working around a weird issue in the framework. Also, I can't use parentheses inside if statements in a template. It's a strange restriction. I know that Jinja2 -- which is good -…

You can use different template engines fairly easily.
Post reply on HN