Skip to content

feat(standings): allow setting definite status from a given round - #8186

Merged
Rathoz merged 3 commits into
mainfrom
claude/swiss-stage-definite-status-611cef
Oct 8, 2026
Merged

Rathoz merged 3 commits into
mainfrom
claude/swiss-stage-definite-status-611cef

Conversation

@Rathoz

@Rathoz Rathoz commented Oct 8, 2026 •

Copy link
Copy Markdown
Member

Summary

Certain teams or players may have their final position type ("up"/"down," etc.) known before all rounds have been played. Currently, we only apply it once the final round is finished, but this PR allows an editor to manually set the status ahead of time.

How did you test this change?

busted and dev

Rathoz and others added 2 commits October 8, 2026 13:00
Editors can set `rXbg=<status>` on an opponent to mark it as definitely
qualified/eliminated from round X onwards, before the stage is finished.
Multiple can be given; each round uses the one with the highest X not
after it.

- Sets both definite and current status, so row and label stay consistent
- Overrides the bg-derived definite status of finished standings;
  disqualifications still override it
- The parser resolves the status from `definiteStatuses` on the opponent
  data, so automatic detection can fill the same field later

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Maps the legacy `r<round>bg<team>` input to `r<round>bg` on the opponent.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 8, 2026 11:02
@Rathoz
Rathoz requested review from a team as code owners October 8, 2026 11:02

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The implementation is consistent across parsing and application paths, with focused coverage for boundaries and disqualification precedence.

0 open findings

What changed in this PR

Adds round-based manual definitive statuses to standings, including legacy Swiss input support and tests.

Changes:

  • Parses r<round>bg statuses and applies them from the specified round onward.
  • Preserves disqualification precedence.
  • Adds parser, wiki-input, and legacy Swiss coverage.
File Description
lua/​wikis/​commons/​Standings/​Table/​Legacy/​Swiss.lua Maps legacy team status inputs.
lua/​wikis/​commons/​Standings/​Table.lua Documents the new opponent field.
lua/​wikis/​commons/​Standings/​Parser.lua Resolves and applies manual statuses.
lua/​wikis/​commons/​Standings/​Parse/​Wiki.lua Parses round-based status inputs.
lua/​spec/​standings_parser_spec.lua Tests status application and precedence.
lua/​spec/​standings_parse_wiki_spec.lua Tests wiki-input parsing.
lua/​spec/​standings_legacy_swiss_spec.lua Tests legacy input mapping.

🧠 Review effort: Balanced


Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.

…finite-status-611cef

# Conflicts:
#	lua/wikis/commons/Standings/Table/Legacy/Swiss.lua
@Rathoz
Rathoz requested a review from hjpalpha October 8, 2026 13:41
@Rathoz
Rathoz merged commit e9f5be6 into main Oct 8, 2026
9 checks passed
@Rathoz
Rathoz deleted the claude/swiss-stage-definite-status-611cef branch October 8, 2026 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants