Skip to content

Skill groups — separate/combined round generation #35

@javaisbetterthanpython

Description

@javaisbetterthanpython

Summary

Upstream: pickleball-shuffler#25 (part 3 of 3)

Round generation for separate vs combined group play, including swing-player placement and edge-case handling.

Separate groups (default)

Combined rounds

Swing players (multi-group membership)

  • Each separate round, swing players assigned to one group by the algorithm to preserve even mix.
  • Edge cases / oddities → assign to higher-priority group (drag order from Skill groups — foundation (data model + UI) #33).
  • Non-swing players stay in their sole group.

Too-small group

  • If a group cannot generate (e.g. <4 players for its court count): block with message.
  • Offer host option to switch to combined round to continue.

Mid-session enable

Acceptance criteria

  • Separate mode: independent schedules per group, shared round numbers
  • Combined mode: merged pool, courts = sum of group courts
  • Per-round separate/combined override
  • Swing player assignment per separate round; higher-priority fallback
  • Too-small group blocks + offers combined fallback
  • Per-group sit-out logic (seamless UI)
  • Integrates with Richer session mix + instant next round #30 diversity rules and Skill groups — court-to-group mapping + rounds layout #34 court layout
  • Automated tests for separate/combined/swing scenarios
  • yarn test:ci and yarn build pass

Files likely touched

  • src/matching/heuristics.ts
  • src/matching/worker.ts
  • src/useShuffler.tsx
  • src/SitoutsModal.tsx
  • pages/rounds.tsx
  • test/heuristics.spec.tsx

Dependencies

Upstream reference

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions