Skip to content

Commit 7efdfad

Browse files
committed
Add CLAUDE instructions
1 parent f8a87d3 commit 7efdfad

File tree

1 file changed

+81
-0
lines changed

1 file changed

+81
-0
lines changed

CLAUDE.md

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# CLAUDE.md
2+
3+
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
4+
5+
## Development Commands
6+
7+
### Backend (Django)
8+
9+
- **Local development**: `docker-compose up` (starts all services)
10+
- **Run tests**: `cd backend && uv run pytest` or `DJANGO_SETTINGS_MODULE=pycon.settings.test uv run pytest`
11+
- **Single test**: `cd backend && uv run pytest path/to/test_file.py::test_function`
12+
- **Lint/format**: `cd backend && uv run ruff check` and `uv run ruff format`
13+
- **Type checking**: `cd backend && uv run mypy .`
14+
- **Django management**: `cd backend && uv run python manage.py <command>`
15+
- **Migrations**: `cd backend && uv run python manage.py makemigrations` and `uv run python manage.py migrate`
16+
17+
### Frontend (Next.js)
18+
19+
- **Local development**: `cd frontend && pnpm dev` (or via docker-compose)
20+
- **Build**: `cd frontend && pnpm build`
21+
- **Tests**: `cd frontend && pnpm test`
22+
- **GraphQL codegen**: `cd frontend && pnpm codegen` (or `pnpm codegen:watch`)
23+
- **Lint/format**: Use Biome via `npx @biomejs/biome check` and `npx @biomejs/biome format`
24+
25+
## Architecture Overview
26+
27+
This is a monorepo for PyCon Italia's website with:
28+
29+
### Backend Structure (Django)
30+
31+
- **API Layer**: GraphQL API using Strawberry at `/backend/api/`
32+
- **Django Apps**: Modular apps in `/backend/` including:
33+
- `conferences/` - Conference management and configuration
34+
- `submissions/` - Talk/proposal submissions
35+
- `users/` - User management and authentication
36+
- `schedule/` - Event scheduling and video uploads
37+
- `sponsors/` - Sponsor management
38+
- `grants/` - Financial assistance program
39+
- `blog/` - Blog posts and news
40+
- `cms/` - Content management via Wagtail
41+
- `api/` - GraphQL schema and resolvers
42+
- **Database**: PostgreSQL with migrations in each app's `migrations/` folder
43+
- **Task Queue**: Celery with Redis backend for async processing
44+
- **Storage**: Configurable (filesystem local, cloud for production)
45+
46+
### Frontend Structure (Next.js)
47+
48+
- **Framework**: Next.js
49+
- **Styling**: Tailwind CSS with custom design system
50+
- **State Management**: Apollo Client for GraphQL
51+
- **Type Safety**: Full TypeScript with generated types from GraphQL schema
52+
- **Location**: `/frontend/src/` contains pages, components, and utilities
53+
54+
### Key Integrations
55+
56+
- **Pretix**: Ticketing system integration for event registration
57+
- **Stripe**: Payment processing
58+
- **ClamAV**: File scanning for security
59+
- **Wagtail**: CMS for page content management
60+
- **Google APIs**: For YouTube video management and calendar integration
61+
62+
## Development Environment
63+
64+
The project uses Docker Compose for local development with services:
65+
66+
- **backend**: Django API server (port 8000)
67+
- **frontend**: Next.js dev server (port 3000)
68+
- **custom-admin**: Admin interface (ports 3002-3003)
69+
- **backend-db**: PostgreSQL database (port 15501)
70+
- **redis**: Caching and task queue
71+
- **clamav**: File virus scanning
72+
73+
## Important Notes
74+
75+
- Python version: 3.13.5+ (specified in pyproject.toml)
76+
- Uses `uv` for Python package management
77+
- Uses `pnpm` for Node.js package management
78+
- GraphQL schema auto-generation from Django backend to frontend
79+
- Test configuration uses separate settings (`pycon.settings.test`)
80+
- Ruff handles both linting and formatting for Python code
81+
- Biome handles linting and formatting for JavaScript/TypeScript

0 commit comments

Comments
 (0)