FastAPI 0.100.0:Release Notes

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • fastapi

    FastAPI framework, high performance, easy to learn, fast to code, ready for production

  • Flask has been around much longer than FastAPI and, as a result, is a much more mature framework. Some examples:

    - There's a memory leak with a particular combination of packages FastAPI [0]

    - Before Pydantic v2, you would validate your data on input (when it's stored in the db) and then every single time on retrieval. There is no way to skip validation, for example, when you are generating a response on data that was already validated when it was persisted to the db. [1]

    - FastAPI has documentation only in the form of tutorials. There is no API documentation and if something is not clear looking through the source code is the only option

    - You need ORJSON for maximum serialisation performance (perhaps this has changed with Pydantic v2) [2]

    - Using FastAPI with uvicorn doesn't respect log format settings [3]

    I don't mean to imply that FastAPI is a bad framework. The Flask ecosystem has had over a decade to mature. FastAPI and the ecosystem will get there but it _needs_ time.

    - [0] https://github.com/tiangolo/fastapi/discussions/9082

  • pydantic

    Data validation using Python type hints

  • Well the performance increase is so huge because pydantic1 is really really slow. And for using rust, I'd have expected more tbh…

    I've been benchmarking pydantic v2 against typedload (which I write) and despite the rust, it still manages to be slower than pure python in some benchmarks.

    The ones on the website are still about comparing to v1 because v2 was not out yet at the time of the last release.

    pydantic's author will refuse to benchmark any library that is faster (https://github.com/pydantic/pydantic/pull/3264 https://github.com/pydantic/pydantic/pull/1525 https://github.com/pydantic/pydantic/pull/1810) and keep boasting about amazing performances.

    On pypy, v2 beta was really really really slow.

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • semver

    Semantic Versioning Specification

  • This is semver:

    > Major version zero (0.y.z) is for initial development. Anything MAY change at any time. The public API SHOULD NOT be considered stable.

    (from https://semver.org/)

  • uvicorn

    An ASGI web server, for Python. 🦄

  • - [3] https://github.com/encode/uvicorn/issues/527

  • pylyzer

    A fast static code analyzer & language server for Python

  • You might want to check Pylyzer then (https://github.com/mtshiba/pylyzer).

    I'm not involved at all. It is still very very early in development. But as it is in the same vein, I thought I'd mentioned it here.

  • msgspec

    A fast serialization and validation library, with builtin support for JSON, MessagePack, YAML, and TOML

  • > Maybe it was very slow before

    That is at least partly the case. I maintain msgspec[1], another Python JSON validation library. Pydantic V1 was ~100x slower at encoding/decoding/validating JSON than msgspec, which was more a testament to Pydantic's performance issues than msgspec's speed. Pydantic V2 is definitely faster than V1, but it's still ~10x slower than msgspec, and up to 2x slower than other pure-python implementations like mashumaro.

    Recent benchmark here: https://gist.github.com/jcrist/d62f450594164d284fbea957fd48b...

    [1]: https://github.com/jcrist/msgspec

  • django-rest-framework

    Web APIs for Django. 🎸

  • I wish Django would take async more seriously. This comment gives a pretty good overview of the current situation (some points are more valid than others): https://github.com/encode/django-rest-framework/discussions/...

    The Python ecosystem is strange. Where other dev communities will embrace new ways of doing things faster than most people can keep up — the Python community needs to be pulled kicking and screaming into the light once ever decade or so. Python 2 to 3, ~10 years.

    async/await has been in Python since 2015, it feels like it's going to be another 5 years before we see people taking async seriously in the big packages. Same problem we had during the 2/3 transition. No library support, no developer support.

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • fastapi-router-controller

    A FastAPI utility to allow Controller Class usage

  • Has litestar CBV (class based views) fastapi refuses to implement them so we build [1]. Or proper lifetime event [2]?

    [1] https://github.com/KiraPC/fastapi-router-controller

  • litestar-pg-redis-docker

    Example Litestar project using Postgresql, Redis and Docker

  • litestar-fullstack

    Litestar Fullstack Reference Application with Vue, Vite, and SQLAlchemy, Docker, Task Queues, and more! (by cofin)

  • https://github.com/cofin/litestar-fullstack - it has Users and Auth , Roles , Teams , Tagging , Data migration , Caching , Background Worker Services , Background scheduling , manage.py-like cli for creating users , admin users , and docker containers.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts