@@ -13,30 +13,24 @@ This project consists of three main components:
1313## Quick Start
1414
1515### Prerequisites
16- - Python 3.8+
17- - Node.js 16+
18- - CPython source repository (for benchmarking)
16+ - Docker Engine 20.10+ and Docker Compose 2.0+
17+ - CPython source repository (for benchmarking with the worker)
1918
2019### Setup & Installation
2120``` bash
22- # Install all dependencies and set up database
23- make setup
21+ # Copy environment config
22+ cp .env.example .env
2423
25- # Or install components separately
26- make install # Install frontend + backend dependencies
27- make init-db # Initialize SQLite database
28- make populate-db # Add mock data for development
24+ # Build and start all services
25+ docker compose -f docker-compose.dev.yml up --build
2926```
3027
3128### Development
32- ``` bash
33- # Start both frontend and backend servers
34- make dev
3529
36- # Or start them individually
37- make dev-frontend # Frontend on http://localhost:9002
38- make dev-backend # Backend API on http://localhost:8000
39- ```
30+ Services start automatically with hot reload:
31+ - Frontend: http://localhost:9002
32+ - Backend API: http://localhost:8000
33+ - API Documentation: http://localhost:8000/api/docs
4034
4135## Development Commands
4236
@@ -53,16 +47,23 @@ npm run typecheck # TypeScript type checking
5347
5448Both checks run in CI on pushes to ` main ` and on pull requests.
5549
56- ### Database Management
50+ ### Populating Mock Data
5751``` bash
58- make reset-db # Drop and recreate database with fresh data
59- make populate-db # Add mock benchmark data
52+ docker compose -f docker-compose.dev.yml exec backend python scripts/populate_db.py
6053```
6154
62- ### Production
55+ ### Updating Backend Dependencies
6356``` bash
64- make build # Build frontend for production
65- make clean # Clean up generated files and caches
57+ # Edit backend/requirements.in, then regenerate both lockfiles:
58+ docker run --rm -v " $( pwd) /backend:/app" -w /app python:3.13-slim-bookworm \
59+ sh -c " pip install --quiet pip-tools && \
60+ pip-compile --strip-extras --generate-hashes \
61+ --output-file requirements.txt requirements.in && \
62+ pip-compile --strip-extras --generate-hashes \
63+ --output-file requirements-dev.txt requirements-dev.in"
64+
65+ # Rebuild the backend container:
66+ docker compose -f docker-compose.dev.yml up --build -d backend
6667```
6768
6869## Worker Setup
@@ -98,10 +99,30 @@ memory-tracker benchmark /path/to/cpython HEAD~5..HEAD \
9899
99100``` bash
100101# Development with hot reload
101- docker- compose -f docker-compose.dev.yml up
102+ docker compose -f docker-compose.dev.yml up
102103
103104# Production deployment
104- docker-compose up
105+ docker compose up
106+ ```
107+
108+ ## Local Development (not recommended)
109+
110+ Running services directly on the host is possible but not recommended.
111+ Docker Compose ensures consistent Python/Node versions, database setup,
112+ and dependency isolation across all platforms.
113+
114+ ### Prerequisites
115+ - Python 3.13+
116+ - Node.js 20+
117+
118+ ``` bash
119+ make setup # Install deps, init DB, populate mock data
120+ make dev # Start frontend + backend with hot reload
121+ make test # Run backend tests
122+ make reset-db # Drop and recreate database with fresh data
123+ make populate-db # Populate the DB with mock data
124+ make build # Build frontend for production
125+ make clean # Clean up generated files and caches
105126```
106127
107128## Usage Examples
@@ -137,7 +158,7 @@ memory-tracker benchmark ~/cpython HEAD~10..HEAD \
137158## Contributing
138159
1391601 . Follow the existing code style and conventions
140- 2 . Run tests before committing: ` make test `
161+ 2 . Run tests before committing
1411623 . Use TypeScript for all frontend code
1421634 . Follow the repository patterns for new features
1431645 . Never commit secrets or authentication tokens
0 commit comments