I found my old project and decided to make it more interesting. So the fact is I restructured the project to change its architecture. Some new features are coming. The web-app is both fullstack and API.
NOTE: .git root is project root;
Python 3.12;FastAPI;PostgreSQL;fastapi_authtools(my authentication library);Pydantic 2.0;Tortoise ORM;Asyncpgasync engine for production and development,aiosqlitefor testing;numpy/pandas/sympy/matplotlibfor calculations;Docker;Vue.js;HTML/CSS/jsfor fullstack;pytestin async mode for testing;rufflinter;
I use Python 3.11 as the project language.
The environment variables seem to be nice, but you can change it with ones you need
(.dev.env for developing, .docker.env for running application in Docker, .test.env for testing).
You can install application requirements with:
pip install -r requirements.txt
First install development requirements with:
pip install -r dev-requirements.txt
To run flake8 linter:
ruff check .
To run tests:
pytest
or write this for more information:
pytest -s -vv
You can run it using Docker. Run this command in the project root directory.
The server is default running at localhost:8000.
docker-compose up -d --build
For local running using uvicorn run:
uvicorn src.main:create_app --reload --port 8000