Skip to content

Comment on Django REST framework 3.15.0

Comments

IMO, DRF is one of the few libraries that can be considered stable and complete. The code is well structured, without a whole lot of hidden magic under the hood (as compared to say Django itself), yet providing immense functionality. I've learnt some neat patterns from digging into the code while working with it

To the devs : well done an Congrats on the release!

What magic does Django have?

By magic I mean the complexity brought on by the heavy use of metaclasses, patterns employed via convention rather than enforced by code (implying that you have to read enough of the code before you understand the patterns) and other similar leaky abstractions.

Don't get me wrong, I do think Django is one of those deep modules[1] where the interface makes it a pleasure to work with but the internals do need effort. Especially the ORM layer.

[1] https://duckduckgo.com/?q=deep+modules+John+Ousterhout&t=fpa...

Imo there's a fair bit of complexity in request dispatch with sync/async interop, wsgi/asgi, channels. I think you end up with something like 10+ frames going through all these pieces before you hit the middlware.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.