Skip to content

rseeley/litestar-before-request-error-mvce

Repository files navigation

Litestar Logo - Light Litestar Logo - Dark

Project Status
CI/CD ci Documentation Building
Quality Coverage Quality Gate Status Maintainability Rating Reliability Rating Security Rating
Package PyPI - Version PyPI - Support Python Versions Starlite PyPI - Downloads Litestar PyPI - Downloads
Community Reddit Discord Matrix Twitter Blog
Meta Litestar Project types - Mypy License - MIT Litestar Sponsors linting - Ruff code style - Black All Contributors

litestar-hello-world

Minimal Litestar Implementation.

Install PDM

Linux/Mac

curl -sSL https://pdm.fming.dev/install-pdm.py | python3 -

Windows

(Invoke-WebRequest -Uri https://pdm.fming.dev/install-pdm.py -UseBasicParsing).Content | python -

Install litestar

pdm install
pdm venv activate
litestar run --reload
curl localhost:8000/sync -w "\n" && curl localhost:8000/async -w "\n"

Litestar Development

If you want to use this app to test a local version of Litestar, change the litestar dependency in pyproject.toml to:

dev = [
    ...
    "litestar @ git+https://github.com/litestar-org/litestar.git",
]

...or you can add it manually with:

pdm add "git+https://github.com/litestar-org/litestar.git" --dev

Note

See PDM - Editable Dependencies for more info.

Run uvicorn or any other ASGI-compliant server from the root of this app:

Important

This assumes that Litestar and this app exist in the same directory.

pdm run uvicorn app:app --reload --reload-dir .

Code Quality

After cloning:

pre-commit install

Run on all files:

pre-commit run --all-files

Run a specific hook:

pre-commit run mypy --all-files

Docs

Important

TODO

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published