Live data from Hacker News

Django 3.2

djangoproject.com

131–140 of 195 posts

Re: Django 3.2

#131
post #123

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…

Awesome project! Bookmarking for sure. Dumb question: after signing up, am I getting some access to a privately hosted repository(pypi.codestasis.com)? How is the mapping between personal/pro plans and features done? Are different plan levels using different repository? Btw, might have overlooked, if I'm purchasing for my org, I would like to look at the commercial license. Can you point me to it? Or put it online if…

Not at all, good question. You do get tokened access to a private PyPI package index, specific to your account and subscription.

At the moment the personal and pro plans use the same repo and infrastructure. But pre-release packages will be listed only for pro accounts.

Here's a preview of the software license (also linked from the subscription page): https://www.codestasis.com/buy/pro/software-license/

Re: Django 3.2

#132

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…

Such a great landing page.

It gets the point across instantly, no bullshit at all. No corporate memphis illustrations [1] and no marketing fluff. Excellence in all manner.

[1] https://www.wired.co.uk/article/corporate-memphis-design-tec...

Re: Django 3.2

#133

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/

Interesting.

How does dokku work with regards to mixed multi-hosting (Apache virtual hosting) on a server?

For example, you have five sites, three are PHP and two are Django. Can it deal with that?

Also a neat "for free" feature of CPanel hosting is that you get super easy email hosting. This can save a lot of money for small and medium businesses. While some would be interested in using Django on these systems, it is in a range between painful and impossible.

This means that you have to now switch to a single-app/domain-per-server scenario (like, Heroku) which is expensive. And then spend more money to host your email elsewhere.

Frankly, this has been one of the largest sources of friction for me with Django. I love the framework and would like to use it exclusively but the transition from local development to deployment can be daunting.

Re: Django 3.2

#134
post #74

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.

At least with pip and env, you'd have a hard time doing general tasks in python without getting to know them anyway. You can also shortcut a lot of that with a hosting service like Heroku, which takes on a lot of the mental overhead for you. You've made me curious to ask, what programming environments don't have a significant learning curve when you get to the hosting portion, short of a "no-code" hosting solution?

PHP. Deploying small-to-medium PHP projects to production has historically been "move these files to your web root, initialize/seed your database if you have one, and that's it." It's really easy to underestimate how valuable that is in certain contexts, and how much that's contributed to PHP virtually owning the low end of the market.

My assumption was always that other languages would find a way to get closer to that model -- never quite to that level for various technical considerations, but close. I'm not sure any really have, save, as you noted, through dedicated hosting services. Fortunately, though, modern PHP frameworks have come to the rescue by becoming far more difficult and fiddly, to the point where both Symfony and Laravel's online tutorials begin with installing Docker.

Re: Django 3.2

#135

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 was in a similar position a few years ago too, until I forced myself to learn Docker.

Now, all my projects are started from the same building blocks: Docker + Django + Gunicorn + Nginx + Postgres. And I love it.

Now I have traefic at the top of My to-learn list so that I can host multiple projects in the same VPS.

Last weekend I learned to use 11ty — the first static site generator I managed to grasp — and I'll entend to use that for projects that don't need this level of "complexity".

Re: Django 3.2

#136
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.

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

It's working out well for the most part, but I don't use React.

I mainly develop server rendered apps and sprinkle in JS as needed.

The only weak link with Tailwind IMO is the lack of JS for doing common things like hiding / showing menus, tooltips, modals, tabs and other stuff you'd find baked into Bootstrap. I know there's some JS included in the TailwindUI components but it's not for JS libraries that I use. I prefer using StimulusJS which isn't something they support at the moment.

Fortunately there's a bunch of StimulusJS Tailwind examples provided by the community so it's not too bad in the end.

I imagine it's hard for Adam because there's React, Vue, Alpine and StimulusJS, all of which are popular enough where there's a good amount of users using them. I'm optimistic that he'll think of a way to cater to all of these users in some way, it'll only be a matter of time. NOTE: This is just speculation, I'm not affiliated with Tailwind in any way.

Re: Django 3.2

#137
post #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.

I just tried to add a new attribute to a many-to-many relationships

Re: Django 3.2

#138
A couple thoughts on django as a long time user. First, the good:

- Django was the first framework i learned when learning to code. It's documentation was amazing, and it made conceptualizing an MVC framework really easy.

- Django's ORM is phenomenal for managing migrations of a relational database, especially postgres with stuff like jsonb. I've even included it in non-python projects, just to handle table migrations/rollbacks.

- The huge ecosystem is amazing. Great for rapid prototyping. Plugins for all kinds of crazy stuff.

Now the bad:

- In some ways it feels like a relic of an earlier stage of python. It's support of asyncio is spotty at best (running the orm in a thread executor not a good work around).

- It's support for type enforcement with mypy is not great. This is maybe my biggest issue with using it on large collaborative projects.

- It doesn't play nicely with a lot of the rest of the python ecosystem. Want to swap in SQLAlchemy? Sorry, no dice. Want to have nice swagger documentation? Use django rest framework or you're out of luck (i know it can be done, but it's kind of messy). So in short, it's a bit of a monolith.

These days I tend to only use django for it's orm in situations where i want a quick ad hoc database for something, or for rapid prototyping. If I'm going to do a larger project in python, I'd definitely go with FastAPI. But still, gotta appreciate that it's there, and has been reliable/well maintained for more than a decade.

Re: Django 3.2

#139
Congratulations to the django team. Having used django for many of my projects for over a decade, it's exciting to see the django community is still going strong and the core members are continuing to push out significant releases such as the 3.2 LTS.

Re: Django 3.2

#140
post #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?

Creating relationships was not a problem but for example, adding new fields to an already created many-2-many was an issue. Changing migration scripts was also a hassle.
Post reply on HN