[t-001] Create pyproject.toml + project scaffolding #1

Open
opened 2026-07-05 08:30:58 +00:00 by david · 0 comments
Owner

Goal

Set up the Python project with correct dependencies, structure, and tooling.

Implementation Steps

Implementation Steps

1. Create pyproject.toml

Write a complete pyproject.toml at /home/david/Projects/keryx-bff/pyproject.toml using this exact content:

[project]
name = "keryx-bff"
version = "0.1.0"
description = "Keryx iOS/iPad Backend For Frontend — FastAPI + Strawberry GraphQL"
requires-python = ">=3.12"
dependencies = [
    "fastapi>=0.115",
    "strawberry-graphql>=0.260",
    "strawberry-graphql[fastapi]",
    "uvicorn[standard]",
    "pydantic>=2.0",
    "pydantic-settings",
    "httpx>=0.28",
    "python-multipart",
    "pyyaml",
    "loguru",
    "aiosqlite",
    "qrcode",
]

[tool.uv]
dev-dependencies = [
    "pytest>=8",
    "pytest-asyncio",
    "httpx",
]

2. Create source directory structure

Create all directories from AGENT.md §5:

cd /home/david/Projects/keryx-bff
mkdir -p src/core src/models src/routes src/services src/lib scripts tests
# Add __init__.py to each subdirectory under src/
for dir in src/core src/models src/routes src/services src/lib; do touch "$dir/__init__.py"; done

3. Verify dependencies install

cd /home/david/Projects/keryx-bff && uv sync
# Expected: no errors, all packages resolved and installed

Verification Gate

Verification Gate

Run:

cd /home/david/Projects/keryx-bff && uv run python -c "import fastapi; import strawberry; import httpx; import pyyaml; print('OK')"
# Expected output: OK

STOP Conditions

STOP Conditions

  • If uv sync fails due to Python version < 3.12, stop and report the issue.
  • If any dependency cannot be resolved, stop and list which packages failed.
## Goal Set up the Python project with correct dependencies, structure, and tooling. ## Implementation Steps ## Implementation Steps ### 1. Create `pyproject.toml` Write a complete pyproject.toml at `/home/david/Projects/keryx-bff/pyproject.toml` using this exact content: ```toml [project] name = "keryx-bff" version = "0.1.0" description = "Keryx iOS/iPad Backend For Frontend — FastAPI + Strawberry GraphQL" requires-python = ">=3.12" dependencies = [ "fastapi>=0.115", "strawberry-graphql>=0.260", "strawberry-graphql[fastapi]", "uvicorn[standard]", "pydantic>=2.0", "pydantic-settings", "httpx>=0.28", "python-multipart", "pyyaml", "loguru", "aiosqlite", "qrcode", ] [tool.uv] dev-dependencies = [ "pytest>=8", "pytest-asyncio", "httpx", ] ``` ### 2. Create source directory structure Create all directories from AGENT.md §5: ```bash cd /home/david/Projects/keryx-bff mkdir -p src/core src/models src/routes src/services src/lib scripts tests # Add __init__.py to each subdirectory under src/ for dir in src/core src/models src/routes src/services src/lib; do touch "$dir/__init__.py"; done ``` ### 3. Verify dependencies install ```bash cd /home/david/Projects/keryx-bff && uv sync # Expected: no errors, all packages resolved and installed ``` ## Verification Gate ## Verification Gate Run: ```bash cd /home/david/Projects/keryx-bff && uv run python -c "import fastapi; import strawberry; import httpx; import pyyaml; print('OK')" # Expected output: OK ``` ## STOP Conditions ## STOP Conditions - If `uv sync` fails due to Python version < 3.12, stop and report the issue. - If any dependency cannot be resolved, stop and list which packages failed.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: david/keryx-bff#1
No description provided.