logoalt Hacker News

btownyesterday at 11:15 PM2 repliesview on HN

On top of this, it's understandable to humans when reviewing generated code. There's no 2000-line FooBarAdmin component where bugs could be located. And if you're having it generate HTML templates, you can see exactly what backend model property/method was used without needing to follow the indirection through backends and prop drilling.

And when you do create backends and React components, you can have a known-good ground truth in your Django admin that's independent from that frontend. This is incredibly useful in practice - if a certain e.g. malformed input triggers a catastrophic frontend crash, you have an entirely separate admin system you can use to play with the data, without needing to trace to find the exact cause of the frontend crash, or dropping into direct database access.

(My one gripe with Django, which is more with the broader Python ecosystem, is that if the community had leaned into the gevent programming model (no explicit async, all socket calls are monkey-patched to yield, you just write sync code), there would be no need for async versions/ports of every Django library function, no confusion in the library ecosystem, and instant upgrades of every Django library in existence to an async world. gevent is a thing of beauty and that's a hill I'll die on.)


Replies

factorialboytoday at 1:22 AM

One meeting with the original gevent author explains why it has not achieved broad acceptability.

It is rather sad for humanity that good ideas through-out time have been lost thanks to neurodiversity / social-acceptability constraints.

Induanetoday at 1:50 AM

I prefer gevent over explicit async so I'll die on that hill with you. The cooperative model adopted by Python async is... bad.