fpy is a high-performance asynchronous HTTP server for Python 3.12+.
- Blazing Fast: Uses C optimizations and an efficient event loop (
uvloop). - Asynchronous: Built on top of Python's
asyncio. - Modern Build System: Uses
Mesonandpyproject.toml. - Clean Architecture: Refactored C-extensions ("Shadow" implementation) for better maintainability.
Requires Python 3.12+ and a C compiler.
pip install .Save as hello.py:
from fpy.app import Application
async def hello(request):
return request.Response(text='Hello world!')
app = Application()
app.router.add_route('/', hello)
app.run()Run server:
python3.12 hello.pycurl http://127.0.0.1:8080/- Build:
python3.12 -m pip install . - Run Tests:
bash verify.sh