4e1211feb6
httpx client with injectable clock/sleep/rng for testability. Successful responses cached under data/bgg_cache/ keyed by endpoint+params; 202 retries follow the spec schedule (2/5/10/30s, give up after 5); 429/503 get jittered exponential backoff; consecutive requests are spaced rate_limit_seconds apart. Parsers (via defusedxml, per security hook) cover search, thing (+stats/+versions), and collection, including the Not Ranked and error-document cases. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
37 lines
687 B
TOML
37 lines
687 B
TOML
[project]
|
|
name = "bggpipe"
|
|
version = "0.1.0"
|
|
description = "Shelf-to-BGG collection pipeline: photos in, BoardGameGeek collection out"
|
|
requires-python = ">=3.12"
|
|
dependencies = [
|
|
"typer>=0.12",
|
|
"httpx>=0.27",
|
|
"rapidfuzz>=3.9",
|
|
"defusedxml>=0.7.1",
|
|
]
|
|
|
|
[project.scripts]
|
|
bggpipe = "bggpipe.cli:app"
|
|
|
|
[dependency-groups]
|
|
dev = [
|
|
"pytest>=8",
|
|
"ruff>=0.5",
|
|
]
|
|
|
|
[build-system]
|
|
requires = ["hatchling"]
|
|
build-backend = "hatchling.build"
|
|
|
|
[tool.ruff]
|
|
target-version = "py312"
|
|
|
|
[tool.ruff.lint]
|
|
select = ["E", "F", "I", "UP", "B", "SIM"]
|
|
|
|
[tool.pytest.ini_options]
|
|
testpaths = ["tests"]
|
|
markers = [
|
|
"live: hits the real BGG API; skipped unless --run-live is passed",
|
|
]
|