andreagrandi / andreagrandi/draftomen
Represent and persist multi-card logical picks
- Ngôn ngữ chính
- Python
- Star
- 0
- Fork
- 0
- Merge trung bình
- 1 giờ 21 phút
- Pull request đã merge (30 ngày)
- 188
Mô tả
## Problem
`PickMadeEvent`, `DraftPick`, pool persistence, idempotence, recovery, and completion reconciliation store one `chosen_grp_id`. Pick-Two selects two cards at one pack/pick coordinate, so logical-pick count and selected-card count are different invariants.
## Proposed change
Cleanly replace singular chosen-card contracts with an immutable collection of selected card IDs across events, draft state, and persistence. Migrate every direct caller in the same change. Preserve coordinate-level idempotence and add every selected card to the pool exactly once.
## Acceptance Criteria
- [ ] A logical pick stores one or more selected card IDs and rejects an empty selection.
- [ ] Quick/Premier/Traditional picks store one card; Pick-Two stores two cards at one coordinate.
- [ ] Logical-pick count and selected-card count are explicit and cannot be confused.
- [ ] Duplicate delivery of an identical multi-card pick is idempotent; conflicting replay is rejected consistently.
- [ ] Pending-pack recovery and completion reconciliation preserve every selected card exactly once.
- [ ] Existing persisted Quick Draft state has a tested clean migration or explicit compatibility strategy.
- [ ] All singular call sites are migrated; no deprecated alias remains.
- [ ] Focused pool/state tests and the changelog cover the new contract.
## Scope notes
No human pick-message parsing, ratings changes, or UI presentation.
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Hướng nghiên cứu
Trace PickMadeEvent and DraftPick through pool persistence, pending-pack recovery, and completion reconciliation to map every singular chosen_grp_id caller. Run the focused pool/state tests while checking coordinate idempotence, migration compatibility, and selected-card counts. Done means all acceptance criteria pass and the changelog documents the new contract.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- python
- Lĩnh vực
- backend, database
- Loại issue
- Tái cấu trúc
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức độ hoạt động
- Sôi nổi
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100