Skip to content

[Backend] — Competition Bracket Generation #1370

Description

@Olowodarey

Labels: backend, enhancement, competitions

Problem

Competitions have participants but no automated bracket/seeding, so organizers must arrange matchups manually.

Requirements

  1. Add an endpoint to generate a bracket from a competition's participants.
  2. Support single-elimination seeding based on a chosen metric.
  3. Persist bracket rounds and matchups.
  4. Handle byes for non-power-of-two participant counts.

Acceptance Criteria

  • A valid bracket is generated for any participant count.
  • Byes are assigned deterministically for odd counts.
  • Bracket structure is persisted and retrievable.
  • Tests cover power-of-two and bye cases.

Files

backend/src/competitions/competitions.service.ts, backend/src/competitions/competitions.controller.ts, backend/src/competitions/entities, backend/src/competitions/dto

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions