Skip to content

Port leaderboard backend from Flask to FastAPI#9

Open
sujata-m wants to merge 1 commit into
testingfrom
feature-fast-apis
Open

Port leaderboard backend from Flask to FastAPI#9
sujata-m wants to merge 1 commit into
testingfrom
feature-fast-apis

Conversation

@sujata-m

@sujata-m sujata-m commented Jul 2, 2026

Copy link
Copy Markdown
Collaborator

Adds a new fastapi-backend service that ports the existing Flask leaderboard APIs to FastAPI while preserving the existing API paths, query params, and response shapes. The implementation uses SQLAlchemy Core models/queries, loads DB config from .env, includes Docker/Compose support, and documents local usage.

Also adds a FastAPI-only health endpoint at GET /api/health that returns API status and database connectivity status, plus .env.example and .gitignore updates for local development.

Adds a new `fastapi-backend` service that ports the existing Flask leaderboard APIs to FastAPI while preserving the existing API paths, query params, and response shapes. The implementation uses SQLAlchemy Core models/queries, loads DB config from `.env`, includes Docker/Compose support, and documents local usage.

Also adds a FastAPI-only health endpoint at `GET /api/health` that returns API status and database connectivity status, plus `.env.example` and `.gitignore` updates for local development.
@sujata-m sujata-m requested a review from susrisha July 2, 2026 05:33
Comment thread fastapi-backend/config.py
database_url = URL.create(
"postgresql+psycopg2",
username=db_user,
password=db_password,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check for url escape. Password may contain '%' character sometimes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants