Repository navigation
feat(standings): show W-D-L in matches column when draws are enabled - #8178
Merged
Merged
Conversation
The matchdiff tiebreaker always displayed W - L, hiding draws. Draws are now resolved once per standings table in the parser: the `matchdraws` wikicode toggle wins when set, otherwise draws are enabled if any match in the table is a draw. Resolving per table (not per round) keeps the format consistent across all rounds. Tiebreakers now receive options with a per-level draw config (match/game/round) via the factory, so game and round level can opt in independently later. Only match level is wired up for now. The stored `hasdraw` flag now reflects the resolved match-level value instead of a hardcoded false. Legacy SwissTableLeague maps `ties` to `matchdraws`, with `auto` meaning auto-detect. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
The legacy Swiss mapping drops boolean ties = false, allowing auto-detection to override an explicit disable.
Review effort: Balanced
Findings: 1
Open (1)
What changed in this PR
Adds draw-aware match records to standings, using explicit toggles or table-wide auto-detection.
Changes:
- Displays W-D-L when match draws are enabled.
- Passes per-level draw options through tiebreakers and updates stored
hasdraw. - Maps legacy Swiss
tiesand adds parser/display tests.
| File | Description |
|---|---|
| lua/wikis/commons/Standings/Tiebreaker/Match/Diff.lua | Displays match draws when enabled. |
| lua/wikis/commons/Standings/Tiebreaker/Interface.lua | Defines per-level draw options. |
| lua/wikis/commons/Standings/Tiebreaker/Factory.lua | Passes options to tiebreakers. |
| lua/wikis/commons/Standings/Table/Legacy/Swiss.lua | Maps legacy ties input. |
| lua/wikis/commons/Standings/Table.lua | Forwards parsed draw configuration. |
| lua/wikis/commons/Standings/Parser.lua | Resolves table-wide draw settings and stores hasdraw. |
| lua/wikis/commons/Standings/Parse/Wiki.lua | Parses the matchdraws toggle. |
| lua/spec/standings_tiebreaker_spec.lua | Tests draw-aware match display. |
| lua/spec/standings_parser_spec.lua | Tests toggles and cross-round auto-detection. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Same result for all wikicode string inputs ('auto' still means
auto-detect), consistent with how `exclusive` is read and keeps a
boolean false intact for any future Lua caller.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
hjpalpha
approved these changes
Oct 7, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
matchdiff) showsW - D - Linstead ofW - Lwhen draws are enabled|matchdraws=true/falseSwissTableLeaguemapstiestomatchdraws(autoinput = auto-detect)hasdrawnow reflects match draws instead of alwaysfalseHow did you test this change?
busted