Skip to content

Refactor the hugo count into more readable form - #518

Merged
offbyone merged 1 commit into
mainfrom
refactor-the-hugo-count-into-more-readable-form/wnynmnkkpouo
Oct 18, 2026
Merged

offbyone merged 1 commit into
mainfrom
refactor-the-hugo-count-into-more-readable-form/wnynmnkkpouo

Conversation

@offbyone

Copy link
Copy Markdown
Contributor

Warren spotted some edge case counting bugs in the Hugo algorithm

this change intros some expected failing tests around those, as well as some new ones that pass, and is focused on refactoring the hugo counter so it's easier to reason about.

Test some edge case scenarios in hugo counting.

All of these are actual issues, albeit only in rare instances:
- when no award wins the IRV, don't have a runoff (this can't change the result, but is weird.)
- 3.12.1: if all remaining finalists are tied, then there should be no tiebreak (which seems to contradict #429); this can affect a rare circumstance where the last tie for elimination tie-breaks out a joint winner
- all tied joint winners when returned should omit No Award -- this is a reporting bug, not critical.

This PR adds extended, currently failing tests for these edge cases
@offbyone offbyone added the patch PR that should result in a patch version update (nitpicks, bugfixes) label Oct 17, 2026
@offbyone
offbyone merged commit 6958761 into main Oct 18, 2026
5 checks passed
@offbyone
offbyone deleted the refactor-the-hugo-count-into-more-readable-form/wnynmnkkpouo branch October 18, 2026 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

patch PR that should result in a patch version update (nitpicks, bugfixes)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant