News for hackers. Stuff that matters.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by Onavo on Saturday March 22, 2025 @11:06AM (#43446204)
No love for Django? I am looking for an alternative to DRF and Django-ninja that can optionally generate typed APIs and docs directly from the model definitions.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by sastraxi on Saturday March 22, 2025 @12:09PM (#43446732)
DRF-spectacular is an okay choice here, you have to manage consistency with return types yourself but the docs and customization options are well done.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by jensenbox on Saturday March 22, 2025 @11:17AM (#43446326)
Why are you looking for an alternative to Django Ninja? What about it is deficient for you? Curious because I am about to use it.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by mariocesar on Saturday March 22, 2025 @11:43AM (#43446568)
Not a technical reason: I've been using Django Ninja to medium/big app with lot of validation logic, and it was a delight. It was easy to start and integrates well with Django, but I'm moving away from it, not because I dislike it, I still like the approach and ergonomics. However, the project seems somewhat abandoned or at least struggling with updates (last release is in August 2024) and with lots of PRs staled. There are forks like django-shinobi https://github.com/pmdevita/django-shinobi that are moving forward and have releases

Right now I'm shifting to FastAPI + Django since much of my logic is already in Pydantic classes, and authentication is token based, so FastAPI mainly is a wrapper for my Django app. Still, it doesn't feel ideal. I would prefer to use django-shinobi, but when I first try to migrate to FastAPI I did it most of the hard stuff in a day

If you're considering options, I recommend giving django-shinobi a try. I hope it gains more traction and involves more maintainers.

Re:Show HN: FastOpenAPI – automated docs for many Python fra... by vital1k on Saturday March 22, 2025 @03:02PM (#43447805)
Hi mariocesar

Django ninja creator here

The project is used in a lot of critical infrastructure so we are prasing more about stability and performance rather then newest featers

On the other hand we prise all fork and keep an eye on them on the features that seems interesting

BTW next relrase is planned by the end of this month

Cheers

Re:Show HN: FastOpenAPI – automated docs for many Python fra... by mariocesar on Saturday March 22, 2025 @03:20PM (#43447936)
Im really happy to hear from you and from Django Ninja!

First off, I just want to say how grateful I am for your work. I know how challenging it can be to maintain opensource projects, and I truly appreciate the effort

Wishing you all the best.

This is a bit unrelated, but something thats been on my mind, how are things for you with everything going on in Ukraine? I cant imagine how difficult it must be to deal with such situation while also staying active in open source

Re:Show HN: FastOpenAPI – automated docs for many Python fra... by ensignavenger on Saturday March 22, 2025 @11:52AM (#43446633)
Django Ninja provides this already for Django, and it is great.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by odie5533 on Sunday March 23, 2025 @08:14AM (#43452409)
Docs are a bit lacking still
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by stackskipton on Saturday March 22, 2025 @11:18AM (#43446337)
There is already plenty available that will do what you want. FastAPI or Litestar are two popular ones.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by mr_Fatalyst on Saturday March 22, 2025 @11:10AM (#43446254)
I actually started working on a router for DRF/Django integration, but Django's project structure made it surprisingly tricky to implement cleanly. It's still on my list though.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by Onavo on Saturday March 22, 2025 @11:20AM (#43446355)
I would suggest having an option for pure Django integration, without DRF.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by scrollaway on Saturday March 22, 2025 @11:19AM (#43446340)
I believe django-ninja is as good as it gets for this, to be honest. But I wouldn't try to support DRF. Django Ninja implements its own routing and it's a lot better that way.
Re:Show HN: FastOpenAPI – automated docs for many Python fra... by Onavo on Saturday March 22, 2025 @11:21AM (#43446361)
Django Ninja isn't particularly well maintained, there have been a few attempts at forking already. Also I think the author of Django Ninja is more concerned about surviving the war right now.