feat(v2): add BCL snapshot extractor and command
This commit is contained in:
24
README.md
24
README.md
@ -185,6 +185,7 @@ Extractor pipeline:
|
||||
Built-in extractor in this phase:
|
||||
- `public_json_snapshot` (generic JSON feed extractor for MVP usage)
|
||||
- `lba` (Lega Basket Serie A MVP extractor)
|
||||
- `bcl` (Basketball Champions League MVP extractor)
|
||||
|
||||
Run extractor:
|
||||
|
||||
@ -210,6 +211,12 @@ Run only the LBA extractor:
|
||||
docker compose exec web python manage.py run_lba_extractor
|
||||
```
|
||||
|
||||
Run only the BCL extractor:
|
||||
|
||||
```bash
|
||||
docker compose exec web python manage.py run_bcl_extractor
|
||||
```
|
||||
|
||||
Extractor environment variables:
|
||||
- `EXTRACTOR_USER_AGENT`
|
||||
- `EXTRACTOR_HTTP_TIMEOUT_SECONDS`
|
||||
@ -223,6 +230,10 @@ Extractor environment variables:
|
||||
- `EXTRACTOR_LBA_SEASON_LABEL`
|
||||
- `EXTRACTOR_LBA_COMPETITION_EXTERNAL_ID`
|
||||
- `EXTRACTOR_LBA_COMPETITION_NAME`
|
||||
- `EXTRACTOR_BCL_STATS_URL`
|
||||
- `EXTRACTOR_BCL_SEASON_LABEL`
|
||||
- `EXTRACTOR_BCL_COMPETITION_EXTERNAL_ID`
|
||||
- `EXTRACTOR_BCL_COMPETITION_NAME`
|
||||
|
||||
Notes:
|
||||
- extraction is intentionally low-frequency and uses retries conservatively
|
||||
@ -239,7 +250,18 @@ Notes:
|
||||
- season is configured by `EXTRACTOR_LBA_SEASON_LABEL`
|
||||
- parser supports payload keys: `records`, `data`, `players`, `items`
|
||||
- normalization supports nested `player` and `team` objects with common stat aliases (`gp/mpg/ppg/rpg/apg/spg/bpg/tov`)
|
||||
- no BCL support in this task
|
||||
- no live HTTP calls in tests; tests use fixtures/mocked responses only
|
||||
|
||||
### BCL extractor assumptions and limitations (MVP)
|
||||
|
||||
- `source_name` is fixed to `bcl`
|
||||
- the extractor expects one stable public JSON payload that includes player/team/stat rows
|
||||
- competition is configured by environment and emitted as:
|
||||
- `competition_external_id` from `EXTRACTOR_BCL_COMPETITION_EXTERNAL_ID`
|
||||
- `competition_name` from `EXTRACTOR_BCL_COMPETITION_NAME`
|
||||
- season is configured by `EXTRACTOR_BCL_SEASON_LABEL`
|
||||
- parser supports payload keys: `records`, `data`, `players`, `items`
|
||||
- normalization supports nested `player` and `team` objects with common stat aliases (`gp/mpg/ppg/rpg/apg/spg/bpg/tov`)
|
||||
- no live HTTP calls in tests; tests use fixtures/mocked responses only
|
||||
|
||||
## Migration and Superuser Commands
|
||||
|
||||
Reference in New Issue
Block a user