Live data from Hacker News

Channels adopted as an official Django project

djangoproject.com

11–20 of 25 posts

Re: Channels adopted as an official Django project

#11
post #2

Good to see Django moving forward. I recently started a Django based project and I'm quite happy so far. Django + DRF.

Can I ask what you like about Django? As a former Django user I've become quite jaded on the framework, and would caution you against using it if you need data integrity, performance, or a complex front-end.

Data integrity is based on your datastore, not a web framework (or even an orm), performance is relative as generally the performance issue in a web application is the database and not the web framework, a complex framework? Just write the front-end with react and build the backend bits in django. I use django every day happily and fail to see any of these as reasons to dislike it.

Now if you had mentioned heavy concurrency I might actually take your comment a bit more seriously. Then the answer is don't use Django or python, use golang or C/Rust.

Re: Channels adopted as an official Django project

#12
post #10

Earlier quoted context omitted.

Can I ask what you like about Django? As a former Django user I've become quite jaded on the framework, and would caution you against using it if you need data integrity, performance, or a complex front-end.

Any chance you could go a bit deeper on these issues? I particularly don't understand the "complex front-end" part. What about django's templating system hinders implementing a rich javascript based UI? I've been quite happy using the templating system to deliver data to the front end and then using whatever js libs / frameworks I've needed to display the data to the user....

He recently did write a blog post about his problems with Django: https://alexcbecker.net/blog.html

Re: Channels adopted as an official Django project

#13
post #2

Good to see Django moving forward. I recently started a Django based project and I'm quite happy so far. Django + DRF.

Can I ask what you like about Django? As a former Django user I've become quite jaded on the framework, and would caution you against using it if you need data integrity, performance, or a complex front-end.

That's one hell of a vague caution.

Vague rebuke: In my experience, Django actually does very well compared to a lot of other solutions. So there.

Re: Channels adopted as an official Django project

#14
post #10

Earlier quoted context omitted.

Any chance you could go a bit deeper on these issues? I particularly don't understand the "complex front-end" part. What about django's templating system hinders implementing a rich javascript based UI? I've been quite happy using the templating system to deliver data to the front end and then using whatever js libs / frameworks I've needed to display the data to the user....

He recently did write a blog post about his problems with Django: https://alexcbecker.net/blog.html

Reading the blog post the complaints on no Data Integrity seem to be a symptom of not using models/data store correctly. Problems not specific to Django or any other web framework.

1. Data races - Use a combination of model versioning and uniqueness checks to prevent data races.

2. get_or_create/update_or_create - Duh, the atomicity is enforced by the parameters you use. Create unique indexes on the model for the things you expect to use in your parameters

Re: Channels adopted as an official Django project

#15
post #14

Earlier quoted context omitted.

He recently did write a blog post about his problems with Django: https://alexcbecker.net/blog.html

Reading the blog post the complaints on no Data Integrity seem to be a symptom of not using models/data store correctly. Problems not specific to Django or any other web framework. 1. Data races - Use a combination of model versioning and uniqueness checks to prevent data races. 2. get_or_create/update_or_create - Duh, the atomicity is enforced by the parameters you use. Create unique indexes on the model for the thi…

I'm not sure I understand the second point here, shouldn't whether a transaction is atomic be independent of indices and data parameters?

Re: Channels adopted as an official Django project

#17
post #2

Good to see Django moving forward. I recently started a Django based project and I'm quite happy so far. Django + DRF.

Can I ask what you like about Django? As a former Django user I've become quite jaded on the framework, and would caution you against using it if you need data integrity, performance, or a complex front-end.

For data integrity and performance I would not necessarily use an ORM, which I used for this project as it was a small backend, rapidly developed to satisfy a business need. However, I think Django can easily handle complex front-ends, data integrity etc - it simply depends on your design choices and especially your data store.

Re: Channels adopted as an official Django project

#18
post #14

Earlier quoted context omitted.

Reading the blog post the complaints on no Data Integrity seem to be a symptom of not using models/data store correctly. Problems not specific to Django or any other web framework. 1. Data races - Use a combination of model versioning and uniqueness checks to prevent data races. 2. get_or_create/update_or_create - Duh, the atomicity is enforced by the parameters you use. Create unique indexes on the model for the thi…

I'm not sure I understand the second point here, shouldn't whether a transaction is atomic be independent of indices and data parameters?

That's explained in blog post, which cites the Django notes.

Re: Channels adopted as an official Django project

#19

Earlier quoted context omitted.

Can I ask what you like about Django? As a former Django user I've become quite jaded on the framework, and would caution you against using it if you need data integrity, performance, or a complex front-end.

That's one hell of a vague caution. Vague rebuke: In my experience, Django actually does very well compared to a lot of other solutions. So there.

I'd like to add that by the time you built your full featured web application on tour favorite microframework with your choice of plugins and custom code, you'll have a partial buggy reimplementation of Django

Re: Channels adopted as an official Django project

#20
post #11

Earlier quoted context omitted.

Can I ask what you like about Django? As a former Django user I've become quite jaded on the framework, and would caution you against using it if you need data integrity, performance, or a complex front-end.

Data integrity is based on your datastore, not a web framework (or even an orm), performance is relative as generally the performance issue in a web application is the database and not the web framework, a complex framework? Just write the front-end with react and build the backend bits in django. I use django every day happily and fail to see any of these as reasons to dislike it. Now if you had mentioned heavy conc…

No, data integrity is not based on your datastore alone. How the app uses it is paramount. It's very easy to write apps that lose all sorts of data due to concurrent requests trampling each other even if you have a DB with the best consistency guarantees possible.

If you have an sql based system and you aren't relying heavily on optimistic/pessimistic locking for record mutation, there is a good chance your system has all kinds of risks to lose data.

Post reply on HN