Skip to content

IvanRublev/python-service-master

Repository files navigation

Webservice template

This is a template for an API webservice in Python.

How to run for local development

  1. Rename the .env-example to .env and specify values for environment variables
  2. Load environment variables use direnv allow in the project's directory
  3. Make sure that you have python and uv installed with asdf install
  4. Install project dependencies with make venv && make deps
  5. Start PostgreSQL container with make containers_up
  6. Migrate database with make migrate_up
  7. Run tests with make test_once, run server with make server

Dependencies

To achieve 2–5 times better performance for network and database operations, the project uses the following standard library replacements:

  • uvloop - libuv-based asyncio event loop
  • asyncpg - async postgresql driver
  • orjson - serialize log records to JSON with C-speed

Copyright

Copyright © 2026 Ivan Rublev.

This project is licensed under the MIT license.

About

Template for an API web service in Python

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors