Skip to content

Refactor API utilities and improve error handling and pagination#7

Merged
Rolv-Arild merged 2 commits into
masterfrom
dev
Apr 30, 2026
Merged

Refactor API utilities and improve error handling and pagination#7
Rolv-Arild merged 2 commits into
masterfrom
dev

Conversation

@Rolv-Arild
Copy link
Copy Markdown
Owner

Refactor util into subpackage and improve API iteration

  • Split ballchasing/util.py into a subpackage: dates, iterators, replays, stats
  • Re-export all util functions from init.py
  • Add prefetching pagination via ThreadPoolExecutor in _iterable_from_request
  • Add deduplicate option to get_replays (by ID keys and date overlap)
  • Add ensure_sorted and mix_replay_iterators utilities
  • Change get_group_tree to yield (path_list, replay) tuples
  • Update typed definitions and constants
  • Move get_maps.py into scripts/
  • Bump version in pyproject.toml

- Split ballchasing/util.py into a subpackage: dates, iterators, replays, stats
- Re-export all util functions from __init__.py
- Add prefetching pagination via ThreadPoolExecutor in _iterable_from_request
- Add deduplicate option to get_replays (by ID keys and date overlap)
- Add ensure_sorted and mix_replay_iterators utilities
- Change get_group_tree to yield (path_list, replay) tuples
- Update typed definitions and constants
- Move get_maps.py into scripts/
- Bump version in pyproject.toml
@Rolv-Arild Rolv-Arild merged commit 4e04177 into master Apr 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant